Note: This is a public test instance of Red Hat Bugzilla. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback at bugzilla.redhat.com.
Bug 733162 - icu-4.4.1-3.fc14 fails to build on ARM due to gcc bug
Summary: icu-4.4.1-3.fc14 fails to build on ARM due to gcc bug
Keywords:
Status: CLOSED NEXTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: icu
Version: 14
Hardware: arm7
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Caolan McNamara
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: ARMTracker
TreeView+ depends on / blocked
 
Reported: 2011-08-24 23:02 UTC by Daniel Drake
Modified: 2011-08-25 15:13 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-08-25 11:33:30 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
test case with instructions inside (502 bytes, text/plain)
2011-08-24 23:02 UTC, Daniel Drake
no flags Details
icu workaround to avoid using GCC atomic builtins on ARM (650 bytes, text/plain)
2011-08-24 23:10 UTC, Daniel Drake
no flags Details

Description Daniel Drake 2011-08-24 23:02:30 UTC
Created attachment 519738 [details]
test case with instructions inside

icu fails to build for ARM on f14:

/usr/bin/ld: ../../make[2]: Leaving directory `/builddir/build/BUILD/icu/source/tools/makeconv'
bin/makeconv: hidden symbol `__sync_val_compare_and_swap_4' in /usr/lib/gcc/armv5tel-redhat-linux-gnueabi/4.5.1/libgcc.a(linux-atomic.o) is referenced by DSO
/usr/bin/ld: final link failed: Nonrepresentable section on output
collect2: ld returned 1 exit status

This is somehow related to http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40134
however, the patches mentioned there are shipped in F14 gcc. hmm.

I narrowed this down to a small test case, which I will attach. To summarise, when using GCC's inbuilt atomic functions in a DSO linked with g++, the atomic function code doesn't get copied from libgcc.a into the output DSO like it should. If linking with gcc instead of g++, it works fine.

The test case is already confirmed to work on F15, so even though this is a gcc bug, I think it would be acceptable to work around this in F14 within the icu package, and dedicate our time to moving to F15+ ASAP.

I'm attaching my proposed workaround. Also, an already-upstream patch is needed from http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=589076

then it builds OK :)

Comment 1 Daniel Drake 2011-08-24 23:10:33 UTC
Created attachment 519741 [details]
icu workaround to avoid using GCC atomic builtins on ARM

Comment 2 Caolan McNamara 2011-08-25 08:54:31 UTC
Checked in both fixes to F14, and the asm one for F15. F16 onwards should have the asm fix already.

That sufficient, or anything else needed ?

Comment 3 Peter Robinson 2011-08-25 15:13:12 UTC
> That sufficient, or anything else needed ?

Absolutely perfect! Thanks for the fixes to all branches and the very quick response :)


Note You need to log in before you can comment on or make changes to this bug.