[Bug binutils/12516] BFD: The first section in the PT_DYNAMIC segment is not the .dynamic section

2011-02-25 Thread sch...@linux-m68k.org
http://sourceware.org/bugzilla/show_bug.cgi?id=12516

--- Comment #4 from Andreas Schwab  2011-02-25 10:18:05 
UTC ---
The linker is red herring, this is all about objcopy.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are on the CC list for the bug.

___
bug-binutils mailing list
bug-binutils@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug binutils/12516] BFD: The first section in the PT_DYNAMIC segment is not the .dynamic section

2011-02-25 Thread amodra at gmail dot com
http://sourceware.org/bugzilla/show_bug.cgi?id=12516

Alan Modra  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution||FIXED

--- Comment #5 from Alan Modra  2011-02-25 12:34:04 
UTC ---
Fixed with http://sourceware.org/bugzilla/show_bug.cgi?id=12519#c2 and
http://sourceware.org/bugzilla/show_bug.cgi?id=12519#c3 wrongly committed with
the wrong PR number.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are on the CC list for the bug.

___
bug-binutils mailing list
bug-binutils@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug gas/12519] size generated from .size _function, .-_function is faulty

2011-02-25 Thread amodra at gmail dot com
http://sourceware.org/bugzilla/show_bug.cgi?id=12519

Alan Modra  changed:

   What|Removed |Added

 Status|NEW |ASSIGNED

--- Comment #5 from Alan Modra  2011-02-25 12:35:15 
UTC ---
Yes, you cannot size a function over two sections like that.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are on the CC list for the bug.

___
bug-binutils mailing list
bug-binutils@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug gas/12519] size generated from .size _function, .-_function is faulty

2011-02-25 Thread cvs-commit at gcc dot gnu.org
http://sourceware.org/bugzilla/show_bug.cgi?id=12519

--- Comment #6 from cvs-commit at gcc dot gnu.org  2011-02-25 13:46:01 UTC ---
CVSROOT:/cvs/src
Module name:src
Changes by:amo...@sourceware.org2011-02-25 13:45:55

Modified files:
gas: ChangeLog 
gas/config : obj-elf.c 
ld/testsuite   : ChangeLog 
ld/testsuite/ld-mn10300: i135409-3.s 
ld/testsuite/ld-sh/sh64: stolib.s 

Log message:
PR gas/12519
* config/obj-elf.c (elf_frob_symbol): Properly handle size expression.
* ld-mn10300/i135409-3.s: Correct .size label reference.
* ld-sh/sh64/stolib.s: Likewise.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gas/ChangeLog.diff?cvsroot=src&r1=1.4410&r2=1.4411
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gas/config/obj-elf.c.diff?cvsroot=src&r1=1.136&r2=1.137
http://sourceware.org/cgi-bin/cvsweb.cgi/src/ld/testsuite/ChangeLog.diff?cvsroot=src&r1=1.1369&r2=1.1370
http://sourceware.org/cgi-bin/cvsweb.cgi/src/ld/testsuite/ld-mn10300/i135409-3.s.diff?cvsroot=src&r1=1.1&r2=1.2
http://sourceware.org/cgi-bin/cvsweb.cgi/src/ld/testsuite/ld-sh/sh64/stolib.s.diff?cvsroot=src&r1=1.1&r2=1.2

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are on the CC list for the bug.

___
bug-binutils mailing list
bug-binutils@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug gas/12519] size generated from .size _function, .-_function is faulty

2011-02-25 Thread cvs-commit at gcc dot gnu.org
http://sourceware.org/bugzilla/show_bug.cgi?id=12519

--- Comment #7 from cvs-commit at gcc dot gnu.org  2011-02-25 13:46:45 UTC ---
CVSROOT:/cvs/src
Module name:src
Branch: binutils-2_21-branch
Changes by:amo...@sourceware.org2011-02-25 13:46:38

Modified files:
gas: ChangeLog 
gas/config : obj-elf.c 
ld/testsuite   : ChangeLog 
ld/testsuite/ld-mn10300: i135409-3.s 
ld/testsuite/ld-sh/sh64: stolib.s 

Log message:
PR gas/12519
* config/obj-elf.c (elf_frob_symbol): Properly handle size expression.
* ld-mn10300/i135409-3.s: Correct .size label reference.
* ld-sh/sh64/stolib.s: Likewise.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gas/ChangeLog.diff?cvsroot=src&only_with_tag=binutils-2_21-branch&r1=1.4320.2.16&r2=1.4320.2.17
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gas/config/obj-elf.c.diff?cvsroot=src&only_with_tag=binutils-2_21-branch&r1=1.133.2.3&r2=1.133.2.4
http://sourceware.org/cgi-bin/cvsweb.cgi/src/ld/testsuite/ChangeLog.diff?cvsroot=src&only_with_tag=binutils-2_21-branch&r1=1.1322.2.5&r2=1.1322.2.6
http://sourceware.org/cgi-bin/cvsweb.cgi/src/ld/testsuite/ld-mn10300/i135409-3.s.diff?cvsroot=src&only_with_tag=binutils-2_21-branch&r1=1.1&r2=1.1.12.1
http://sourceware.org/cgi-bin/cvsweb.cgi/src/ld/testsuite/ld-sh/sh64/stolib.s.diff?cvsroot=src&only_with_tag=binutils-2_21-branch&r1=1.1&r2=1.1.30.1

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are on the CC list for the bug.

___
bug-binutils mailing list
bug-binutils@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug gas/12519] size generated from .size _function, .-_function is faulty

2011-02-25 Thread amodra at gmail dot com
http://sourceware.org/bugzilla/show_bug.cgi?id=12519

Alan Modra  changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution||FIXED

--- Comment #8 from Alan Modra  2011-02-25 13:49:21 
UTC ---
Fixed.  Ignore commit messages in comment 2 and 3, which belong to PR12516.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are on the CC list for the bug.

___
bug-binutils mailing list
bug-binutils@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug binutils/12516] BFD: The first section in the PT_DYNAMIC segment is not the .dynamic section

2011-02-25 Thread cvs-commit at gcc dot gnu.org
http://sourceware.org/bugzilla/show_bug.cgi?id=12516

--- Comment #6 from cvs-commit at gcc dot gnu.org  2011-02-25 15:53:27 UTC ---
CVSROOT:/cvs/src
Module name:src
Changes by:h...@sourceware.org2011-02-25 15:53:25

Modified files:
ld/testsuite   : ChangeLog 
Added files:
ld/testsuite/ld-elf: dynamic1.d dynamic1.ld dynamic1.s 

Log message:
Add a testcase for PR ld/12516.

2011-02-25  H.J. Lu  

PR ld/12516
* ld-elf/dynamic1.d: New.
* ld-elf/dynamic1.ld: Likewise.
* ld-elf/dynamic1.s: Likewise.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/src/ld/testsuite/ChangeLog.diff?cvsroot=src&r1=1.1370&r2=1.1371
http://sourceware.org/cgi-bin/cvsweb.cgi/src/ld/testsuite/ld-elf/dynamic1.d.diff?cvsroot=src&r1=NONE&r2=1.1
http://sourceware.org/cgi-bin/cvsweb.cgi/src/ld/testsuite/ld-elf/dynamic1.ld.diff?cvsroot=src&r1=NONE&r2=1.1
http://sourceware.org/cgi-bin/cvsweb.cgi/src/ld/testsuite/ld-elf/dynamic1.s.diff?cvsroot=src&r1=NONE&r2=1.1

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are on the CC list for the bug.

___
bug-binutils mailing list
bug-binutils@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug gas/12519] size generated from .size _function, .-_function is faulty

2011-02-25 Thread cvs-commit at gcc dot gnu.org
http://sourceware.org/bugzilla/show_bug.cgi?id=12519

--- Comment #9 from cvs-commit at gcc dot gnu.org  2011-02-25 17:00:33 UTC ---
CVSROOT:/cvs/src
Module name:src
Changes by:h...@sourceware.org2011-02-25 17:00:30

Modified files:
gas/testsuite  : ChangeLog 
gas/testsuite/gas/elf: elf.exp 
Added files:
gas/testsuite/gas/elf: bad-size.d bad-size.err bad-size.s 

Log message:
Add a testcase for PR gas/12519.

2011-02-25  H.J. Lu  

PR gas/12519
* gas/elf/bad-size.d: New.
* gas/elf/bad-size.err: Likewise.
* gas/elf/bad-size.s: Likewise.

* gas/elf/elf.exp: Run bad-size.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gas/testsuite/ChangeLog.diff?cvsroot=src&r1=1.1853&r2=1.1854
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gas/testsuite/gas/elf/bad-size.d.diff?cvsroot=src&r1=NONE&r2=1.1
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gas/testsuite/gas/elf/bad-size.err.diff?cvsroot=src&r1=NONE&r2=1.1
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gas/testsuite/gas/elf/bad-size.s.diff?cvsroot=src&r1=NONE&r2=1.1
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gas/testsuite/gas/elf/elf.exp.diff?cvsroot=src&r1=1.74&r2=1.75

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are on the CC list for the bug.

___
bug-binutils mailing list
bug-binutils@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-binutils


Race condition when building binutils with a system libopcodes

2011-02-25 Thread Loïc Minier
Hi there

 
http://people.linaro.org/~lool/buildlog_ubuntu-natty-i386.binutils_2.21.0.20110216-1ubuntu2_FAILEDTOBUILD.txt.gz.txt
 shows a failed build log of binutils; this build is done with make -j8.

 The relevant part is:
g++-4.4 -DHAVE_CONFIG_H -I. -I../../gold  -I../../gold -I../../gold/../include 
-I../../gold/../elfcpp -DLOCALEDIR="\"/usr/share/locale\"" 
-DBINDIR="\"/usr/bin\"" -DTOOLBINDIR="\"/usr/i686-linux-gnu/bin\""   -W -Wall   
 -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -frandom-seed=incremental.o -g -O2 
-MT incremental.o -MD -MP -MF .deps/incremental.Tpo -c -o incremental.o 
../../gold/incremental.cc
mv -f .deps/i386-opc.Tpo .deps/i386-opc.Plo
/bin/bash ./libtool --tag=CC   --mode=link gcc-4.4 -W -Wall -Wstrict-prototypes 
-Wmissing-prototypes -Wshadow -g -O2 -Wno-format-security  -release `cat 
../bfd/libtool-soversion`  -Wl,-Bsymbolic-functions -o libopcodes.la -rpath 
/usr/lib dis-buf.lo disassemble.lo dis-init.lo i386-dis.lo i386-opc.lo 
-Wl,/build/buildd/binutils-2.21.0.20110216/builddir-single/opcodes/../bfd/.libs/libbfd.so
 
-L/build/buildd/binutils-2.21.0.20110216/builddir-single/opcodes/../libiberty/pic
 -liberty -Wl,-lc,--as-needed,-lm,--no-as-needed 
libtool: link: gcc-4.4 -shared  .libs/dis-buf.o .libs/disassemble.o 
.libs/dis-init.o .libs/i386-dis.o .libs/i386-opc.o   
-L/build/buildd/binutils-2.21.0.20110216/builddir-single/opcodes/../libiberty/pic
 -liberty  -Wl,-Bsymbolic-functions 
-Wl,/build/buildd/binutils-2.21.0.20110216/builddir-single/opcodes/../bfd/.libs/libbfd.so
 -Wl,-lc -Wl,--as-needed -Wl,-lm -Wl,--no-as-needed   -Wl,-soname 
-Wl,libopcodes-2.21.0-system.20110216.so -o 
.libs/libopcodes-2.21.0-system.20110216.so
as: error while loading shared libraries: 
/build/buildd/binutils-2.21.0.20110216/builddir-single/./opcodes/.libs/libopcodes-2.21.0-system.20110216.so:
 file too short
make[5]: *** [gold-threads.o] Error 1
make[5]: *** Waiting for unfinished jobs
libtool: link: (cd ".libs" && rm -f "libopcodes.so" && ln -s 
"libopcodes-2.21.0-system.20110216.so" "libopcodes.so")
libtool: link: ar cru .libs/libopcodes.a  dis-buf.o disassemble.o dis-init.o 
i386-dis.o i386-opc.o
libtool: link: ranlib .libs/libopcodes.a
libtool: link: ( cd ".libs" && rm -f "libopcodes.la" && ln -s 
"../libopcodes.la" "libopcodes.la" )
libtooldir=`/bin/bash ./libtool --config | sed -n -e 's/^objdir=//p'`; \
if [ -f $libtooldir/libopcodes.a ]; then \
  cp $libtooldir/libopcodes.a libopcodes.tmp; \
  ranlib libopcodes.tmp; \
  /bin/bash ../../opcodes/../move-if-change libopcodes.tmp 
libopcodes.a; \
else true; fi
touch stamp-lib
make[5]: Leaving directory 
`/build/buildd/binutils-2.21.0.20110216/builddir-single/opcodes'

 what seems to happen here is that the build breaks (in gold) at the exact
 moment where libopcodes is being built with an error:
as: error while loading shared libraries: 
/build/buildd/binutils-2.21.0.20110216/builddir-single/./opcodes/.libs/libopcodes-2.21.0-system.20110216.so:
 file too short

 My interpretation is that the system's as which is used to build
 binutils depends on libopcodes-2.21.0-system.20110216.so which is being
 built here; ldd /usr/bin/as:
linux-vdso.so.1 =>  (0x7fff9349c000)
libopcodes-2.21.0-system.20110216.so => 
/usr/lib/libopcodes-2.21.0-system.20110216.so (0x7f93fbfd6000)
libbfd-2.21.0-system.20110216.so => 
/usr/lib/libbfd-2.21.0-system.20110216.so (0x7f93fbce6000)
libdl.so.2 => /lib/libdl.so.2 (0x7f93fbae1000)
libz.so.1 => /lib/libz.so.1 (0x7f93fb8c9000)
libc.so.6 => /lib/libc.so.6 (0x7f93fb523000)
/lib64/ld-linux-x86-64.so.2 (0x7f93fc2de000)

 I suspect libtool manipulates LD_LIBRARY_PATH as to allow the linker to
 find libs in the libtool .libs directory and that "as" fails to start
 when another part of the build is generating a
 libopcodes-2.21.0-system.20110216.so in such a .libs.

 Does that sound like a plausible explanation, and is this a libtool or
 a binutils bug?  :-)

   Thanks!

NB:
* just retrying the build, and it passes, so it is racy; presumably
  depends whether a process starts when libopcode is being written
* I guess this could happen with libbfd too; depends whether the
  binutils build-system or libtool is adding which libdirs and for how
  long I guess
-- 
Loïc Minier

___
bug-binutils mailing list
bug-binutils@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-binutils


macro defining 16-bit address offset from and offset

2011-02-25 Thread Skacore Systems
Hello !

I'm trying to get working following simple macro for hours, but still no
success. I just want to define two bytes,
one containing length of the data and the other one an address - but in
words, and therefore divided / 2 ( or >> 1)
Is there any chances to get it working ? Please add me into CC i'm not
subscribed.

.macro link_data astart, aend
.byte \aend - \astart
.byte \astart / 2
.endm

.globl eeprom_start
eeprom_start:
link_data Manufacturer_ID_String,  Manufacturer_ID_String_end
Manufacturer_ID_String:
.ascii  "Skacore Systems.\0"
Manufacturer_ID_String_end:

.globl eeprom_end
eeprom_end:

gas output:

as test.S -o test.o
test.S: Assembler messages:
test.S:26: Error: invalid sections for operation on `Manufacturer_ID_String'
and `L0'
___
bug-binutils mailing list
bug-binutils@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-binutils


Re: macro defining 16-bit address offset from and offset

2011-02-25 Thread Alan Modra
On Fri, Feb 25, 2011 at 03:16:08PM +0100, Skacore Systems wrote:
> .byte \astart / 2

This is the problem.

> as test.S -o test.o
> test.S: Assembler messages:
> test.S:26: Error: invalid sections for operation on `Manufacturer_ID_String'
> and `L0'

You can't divide a relocatable symbol like Manufacturer_ID_String by
two (unless your target happens to have a relocation that would allow
the linker to perform the divide for you).

-- 
Alan Modra
Australia Development Lab, IBM

___
bug-binutils mailing list
bug-binutils@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug gold/12507] Can't build a program with -flto -nostdlib

2011-02-25 Thread cvs-commit at gcc dot gnu.org
http://sourceware.org/bugzilla/show_bug.cgi?id=12507

--- Comment #5 from cvs-commit at gcc dot gnu.org  2011-02-26 04:38:38 UTC ---
CVSROOT:/cvs/src
Module name:src
Changes by:h...@sourceware.org2011-02-26 04:38:35

Modified files:
ld : ChangeLog plugin.c 

Log message:
Add entry_symbol chain into non_ironly_hash.

2011-02-24  H.J. Lu  

PR ld/12507
* plugin.c (get_symbols): Don't check entry symbol here.
(init_non_ironly_hash): Add entry_symbol chain into
non_ironly_hash.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/src/ld/ChangeLog.diff?cvsroot=src&r1=1.2285&r2=1.2286
http://sourceware.org/cgi-bin/cvsweb.cgi/src/ld/plugin.c.diff?cvsroot=src&r1=1.24&r2=1.25

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are on the CC list for the bug.

___
bug-binutils mailing list
bug-binutils@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-binutils