Bug 750805 - Fails to build on ARM, needs to use default setjmp not ucontext
Summary: Fails to build on ARM, needs to use default setjmp not ucontext
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: perl-Coro
Version: 17
Hardware: arm
OS: Linux
unspecified
unspecified
Target Milestone: ---
Assignee: Petr Pisar
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-11-02 12:21 UTC by Henrik Nordström
Modified: 2015-07-13 11:12 UTC (History)
8 users (show)

Fixed In Version: perl-Coro-6.07-3.fc17
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-02-22 17:43:53 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
Disable ucontext forced default on arm, using normal setjmp default. (475 bytes, patch)
2011-11-03 09:00 UTC, Henrik Nordström
no flags Details | Diff
Disable FORTIFY_SOURCE on ARM, incompatible with how setjmp is used. (529 bytes, patch)
2011-11-04 01:39 UTC, Henrik Nordström
no flags Details | Diff


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 1242138 0 unspecified CLOSED perl-Coro-6.47 is available 2021-02-22 00:41:40 UTC

Internal Links: 1242138 2165855

Description Henrik Nordström 2011-11-02 12:21:40 UTC
Description of problem:

ARM do not implement the needed ucontext functions, and need to use the default setjmp method. This is normally the default, except that fedora patches it to hardwire ucontext as default method..

Version-Release number of selected component (if applicable):

perl-Coro-5.372-3.fc15

How reproducible:

always

Steps to Reproduce:
1. Try to rebuild perl-Coro on arm
2.
3.
  
Actual results:

failed build, crashing in testsuite

Expected results:

successful build

Additional info:

Trivial spec file patch attached.

Please apply patch and sumbit a F15 koji build from which arm can pull the srpm. update request is not stricty needed if the only change relative to current F15 build is this patch.

Comment 1 Nicolas Chauvet (kwizart) 2011-11-02 13:20:55 UTC
Hi Henrik,

Isn't the attachment missing ?

Comment 2 Henrik Nordström 2011-11-03 09:00:28 UTC
Created attachment 531517 [details]
Disable ucontext forced default on arm, using normal setjmp default.

Indeed. Could have sworn I added it when filing the bug.

Comment 3 Petr Pisar 2011-11-03 15:53:34 UTC
Nicolas, thank you for taking it. I found I cannot rebuild it in F17 because SELinux denies executable non-text memory. I haven't found what to do yet. (A pax marker?)

Comment 4 Fedora Update System 2011-11-03 16:32:22 UTC
perl-Coro-5.372-6.fc16 has been submitted as an update for Fedora 16.
https://admin.fedoraproject.org/updates/perl-Coro-5.372-6.fc16

Comment 5 Fedora Update System 2011-11-03 16:34:02 UTC
perl-Coro-5.372-4.fc15 has been submitted as an update for Fedora 15.
https://admin.fedoraproject.org/updates/perl-Coro-5.372-4.fc15

Comment 6 Henrik Nordström 2011-11-04 01:39:51 UTC
Created attachment 531681 [details]
Disable FORTIFY_SOURCE on ARM, incompatible with how setjmp is used.

Thanks. Unfortunately it turns out additional changes is needed on arm. The way Coro uses setjmp is incompatible with FORTIFY_SOURCE.

Comment 7 Fedora Update System 2011-11-04 20:26:25 UTC
Package perl-Coro-5.372-4.fc15:
* should fix your issue,
* was pushed to the Fedora 15 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing perl-Coro-5.372-4.fc15'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2011-15373
then log in and leave karma (feedback).

Comment 8 Nicolas Chauvet (kwizart) 2011-11-04 22:12:57 UTC
(In reply to comment #6)
> Created attachment 531681 [details]
> Disable FORTIFY_SOURCE on ARM, incompatible with how setjmp is used.
> 
> Thanks. Unfortunately it turns out additional changes is needed on arm. The way
> Coro uses setjmp is incompatible with FORTIFY_SOURCE.
Is this a build or runtime issue ?
Can we have additional info about wgy it fails with FORTIFY_SOURCE ?

Comment 9 Henrik Nordström 2011-11-05 08:52:26 UTC
It's a runtime issue detected by the test suite. I by accident did not have FORTIFY_SOURCE enabled when testing the first change.

Coro (and pth) both abuses setjmp in the same manner for establishing new stacks per context, but with FORTIFY_SOURCE enabled glibc verifies that setjmp only sets the stack pointer to an earlier stack frame in the current stack and aborts if the stack change looks odd.

*** longjmp causes uninitialized stack frame ***: /usr/bin/perl terminated

it's a valid error message in normal specified use of setjmp, but do not apply to the special (outside specifications) use by Coro for establishing another stack context entirely, outside the current stack.

Comment 10 Fedora Update System 2011-12-12 21:58:42 UTC
perl-Coro-5.372-6.fc16 has been pushed to the Fedora 16 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 11 Brendan Conoboy 2012-02-21 20:41:16 UTC
This appears to be broken again in F17 and Rawhide.

Comment 12 Mark Langsdorf 2012-02-21 20:43:53 UTC
(In reply to comment #11)
> Created attachment 531681 [details]
> Disable FORTIFY_SOURCE on ARM, incompatible with how setjmp is used.

This patch didn't make it into the F17 and Rawhide version and compile fails with the "*** longjmp causes uninitialized stack frame ***: /usr/bin/perl terminated" message.

Re-applying the patch allows the package to be built.

Comment 13 Fedora Update System 2012-02-22 09:35:44 UTC
perl-Coro-6.07-3.fc17 has been submitted as an update for Fedora 17.
https://admin.fedoraproject.org/updates/FEDORA-2012-2192/perl-Coro-6.07-3.fc17

Comment 14 Brendan Conoboy 2012-02-22 17:43:53 UTC
Thanks, perl-Coro-6.07-3.fc17 builds successfully on ARM.

Comment 15 Fedora Update System 2012-02-28 10:48:20 UTC
perl-Coro-6.07-3.fc17 has been pushed to the Fedora 17 stable repository.  If problems still persist, please make note of it in this bug report.


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