Bug 339931

Summary: shapelib build fails because of missing build-id flag to ld
Product: [Fedora] Fedora Reporter: Doug Chapman <dchapman>
Component: shapelibAssignee: Shawn McCann <mccann0011>
Status: CLOSED RAWHIDE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: high Docs Contact:
Priority: high    
Version: rawhideCC: roland
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2007-10-28 02:01:33 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 163350    
Attachments:
Description Flags
patch to add --build-id flag to LD none

Description Doug Chapman 2007-10-19 15:49:02 UTC
Description of problem:
In fedora 8 the find-debuginfo script used by rpmbuild to make the debuginfo
package requires that all binaries had the build id info.  When linking is done
via gcc this happens automatically as --build-id is always passed to the linker
in recent versions of Fedora 8's gcc however when a build script calls ld
directly it must pass --build-id itself.

Attached is a patch for the shapelib Makefile to add this.

I am adding Roland to the cc list as he can answer any questions regarding why
--build-id is now needed.


Version-Release number of selected component (if applicable):
shapelib-1.2.10-12.20060304cvs.src.rpm

How reproducible:
100%

Steps to Reproduce:
On a Fedora 8 Test 3 system
1. rpmbuild --rebuild -bb shapelib-1.2.10-12.20060304cvs.src.rpm
2.
3.
  
Actual results:
fails in find-debuginfo.sh


Expected results:


Additional info:

Comment 1 Doug Chapman 2007-10-19 15:49:02 UTC
Created attachment 232691 [details]
patch to add --build-id flag to LD

Comment 2 Roland McGrath 2007-10-19 20:23:17 UTC
The right fix is to use $(CC) instead of $(LD) for creating the DSO.
In that example, you may have to rewrite -G -h foo as -shared -Wl,-soname,foo to
get those options down correctly.  The --build-id switch is not the only thing
missing/wrong in creating a DSO with ld directly, it's just the one we now
notice as a hard error.

Comment 3 Shawn McCann 2007-10-22 04:47:03 UTC
OK, I'll submit the basic fix for now and the more complete fix later this week.
Tried submitting the update tonight but apparently now need to use koji instead
of plague to run builds. Will sort this out tomorrow night.

Comment 4 Shawn McCann 2007-10-28 02:02:29 UTC
Have submitted the basic patch and tested the build. Will fix the Makefile to
use $(CC) instead of $(LD) in the next update