configure: error: GRUB requires a working absolute objcopy; upgrade your binutils

Bug #426419 reported by Lars Noodén
24
This bug affects 5 people
Affects Status Importance Assigned to Milestone
grub (Debian)
Fix Committed
Undecided
Unassigned
grub (Ubuntu)
Fix Released
Medium
Colin Watson

Bug Description

./configure (for grub 0.97 source) gives this error on Karmic Koala Alpha 5 for i386:

checking whether objcopy works for absolute addresses... no
configure: error: GRUB requires a working absolute objcopy; upgrade your binutils

binutils is the latest available so there seems to be a problem with objcopy

$ lsb_release -rd
Description: Ubuntu karmic (development branch)
Release: 9.10

$ apt-cache show binutils
Package: binutils
Priority: optional
Section: devel
Installed-Size: 9564
Maintainer: Ubuntu Core developers <email address hidden>
Original-Maintainer: Matthias Klose <email address hidden>
Architecture: i386
Version: 2.19.51.20090827-1ubuntu1
Provides: elf-binutils
Depends: libc6 (>= 2.8), zlib1g (>= 1:1.1.4)
Suggests: binutils-doc (>= 2.19.51.20090827-1ubuntu1)
Conflicts: elf-binutils, gas, modutils (<< 2.4.19-1)
Filename: pool/main/b/binutils/binutils_2.19.51.20090827-1ubuntu1_i386.deb
Size: 1653974
MD5sum: f75c9f5c8a9c7bd28d4b0a337916587b
SHA1: 1ae21a988fbdb46231de457176c717bd4b420799
SHA256: 081886734173055018aae21cff2a72544d28b35a8d7a24bdba2b7e9ca9c29d8d
Description: The GNU assembler, linker and binary utilities
 The programs in this package are used to assemble, link and manipulate
 binary and object files. They may be used in conjunction with a compiler
 and various libraries to build programs.
Bugs: https://bugs.launchpad.net/ubuntu/+filebug
Build-Essential: yes
Origin: Ubuntu
Task: ubuntu-desktop, kubuntu-desktop, kubuntu-netbook, edubuntu-desktop, xubuntu-desktop, mythbuntu-backend-master, mythbuntu-backend-slave, mythbuntu-desktop, mythbuntu-frontend, ubuntu-netbook-remix

$ uname -a
Linux mini 2.6.31-9-generic #29-Ubuntu SMP Sun Aug 30 17:39:23 UTC 2009 i686 GNU/Linux

Revision history for this message
Matthias Klose (doko) wrote :

confirmed with 2.19.91.20090910, grub2 builds fine

Changed in binutils (Ubuntu):
importance: Undecided → Medium
status: New → Triaged
Noiano (noiano)
Changed in binutils (Ubuntu):
status: Triaged → In Progress
Revision history for this message
Colin Watson (cjwatson) wrote :

This wasn't a bug in binutils (grub's configure message was in error), and I fixed this in the grub package in 9.10.

grub (0.97-29ubuntu58) karmic; urgency=low

  * objcopy-absolute.diff (update): Remove .note, .comment, and
    .note.gnu.build-id sections from images (LP: #444703).

 -- Colin Watson <email address hidden> Tue, 06 Oct 2009 19:19:05 +0100

grub (0.97-29ubuntu57) karmic; urgency=low

  * cache_coherency.diff (update): Add Debian bug link.
  * objcopy-absolute.diff: Backport from grub2 (Lubomir Kundrak): take only
    .text section into account, as newer toolchains generate unique build
    ids.

 -- Colin Watson <email address hidden> Tue, 06 Oct 2009 10:57:44 +0100

affects: binutils (Ubuntu) → grub (Ubuntu)
Changed in grub (Ubuntu):
assignee: nobody → Colin Watson (cjwatson)
status: In Progress → Fix Released
Revision history for this message
Ravikiran D Borse (ravidborse) wrote :

To Solve this error just do minute changes in configure file

Below is the Snippet of configure file:

echo $ECHO_N "checking whether ${OBJCOPY} works for absolute addresses...
....
....
[B]for link_addr in 0x2000 0x8000 0x7C00; do [/B]
....
....
[B] if { ac_try='${OBJCOPY-objcopy} --only-section=.text -O binary conftest.exec conftest'[/B]
....
....

The Lines in Bold Format or with [B] symbol, just replace this lines

Revision history for this message
Colin Watson (cjwatson) wrote : Re: [Bug 426419] Re: configure: error: GRUB requires a working absolute objcopy; upgrade your binutils

On Sat, Jul 23, 2011 at 03:35:26PM -0000, Ravikiran D Borse wrote:
> To Solve this error just do minute changes in configure file

Thanks, but I solved this problem long ago - see the bug log.

Revision history for this message
AreYouLoco? (areyouloco++) wrote :

same error compiling grub:
checking for objcopy... objcopy
checking if C symbols get an underscore after compilation... no
checking whether objcopy works for absolute addresses... no
configure: error: GRUB requires a working absolute objcopy; upgrade your binutils

Changed in grub (Debian):
status: New → Fix Committed
Revision history for this message
Colin Watson (cjwatson) wrote :

@areyouloco++: What version of grub is this? We fixed this in all known versions some time ago.

Revision history for this message
dhiraj (dhirajbhor21) wrote :

Thanks a ton @ravidborse and all.
I just followed your steps and it worked.
It helped me on Debian 8 (Jessie).

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.