Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 1322524 - Fix build on MIPS
Summary: Fix build on MIPS
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: qt
Version: 25
Hardware: mips64
OS: Linux
unspecified
unspecified
Target Milestone: ---
Assignee: Rex Dieter
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: MIPS
TreeView+ depends on / blocked
 
Reported: 2016-03-30 16:05 UTC by Michal Toman
Modified: 2016-12-05 13:54 UTC (History)
9 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-12-05 13:54:24 UTC


Attachments (Terms of Use)
Fix-build-on-MIPS.patch (deleted)
2016-03-30 16:05 UTC, Michal Toman
no flags Details | Diff
Fix-build-on-MIPS.patch (deleted)
2016-04-04 18:14 UTC, Michal Toman
no flags Details | Diff

Description Michal Toman 2016-03-30 16:05:21 UTC
Created attachment 1141832 [details]
Fix-build-on-MIPS.patch

Description of problem:
We are trying to bring Fedora to MIPS platform and this requires making qt specfila MIPS-aware. Also for some reason mips64 is evaluated as unsupported even though it works. An override is therefore required.

Actual results:
MIPS is not included in multilib archs, mips64 build falls back to 'generic'

Expected results:
MIPS is included in multilib archs, mips64 builds 'mips'

Additional info:
Attaching dist-git patch. It would be great if this could also be applied to F24.

Comment 1 Rex Dieter 2016-03-31 15:16:09 UTC
2 questions:

1. Are you sure you want to use linux-g++ on mips64 ?

Per old bug #569542 on the topic,

it would appear that qt's 
src/corelib/arch/mips/arch.pri

includes qatomic assembly depending on if platform includes -64 suffix or not:

*-64:SOURCES += $$QT_ARCH_CPP/qatomic_mips64.s
else:SOURCES += $$QT_ARCH_CPP/qatomic_mips32.s


2.  why is '-arch mips' needed?  I assume because the autodetection fails?  (If so, I think I would prefer to fix/patch the autodetection rather than workaround it this way)

Comment 2 Michal Toman 2016-03-31 15:25:16 UTC
1. I am sure with linux-g++, MIPS does not accept -m32/-m64 GCC flags and linux-g++-64 appends -m64.

2. '-arch mips' is only needed on 64-bit, 'mips64' fails autodetection and uses 'generic' implementation. Let me prepare a patch.

Comment 3 Rex Dieter 2016-03-31 15:38:11 UTC
So, given comment #2, 
1.  I think keeping -platform linux-g++-64 (to use proper atomics) and patching mkspecs to not use -m64/-m32 flags (on mips) is the way to go

2. On second though, I guess qt(4) upstream development has essentially stopped, so fixing autodetection and getting that upstreamed is less likely... so, conditionally overriding -arch mips on mips64 is ok with me

Comment 4 Michal Toman 2016-03-31 15:49:53 UTC
(In reply to Rex Dieter from comment #3)
> So, given comment #2, 
> 1.  I think keeping -platform linux-g++-64 (to use proper atomics) and
> patching mkspecs to not use -m64/-m32 flags (on mips) is the way to go

Ah I see, I have misread your previous comment. You are right, let me prepare a patch for this part.

Thanks for your suggestions.

Comment 5 Michal Toman 2016-04-04 18:14:11 UTC
Created attachment 1143410 [details]
Fix-build-on-MIPS.patch

I've managed to patch configure to fix mips64 autodetection. I've also tried to patch linux-g++-64/qmake.conf to remove -m64 on mips64 but this is kind of tricky to do just for mips64 (the patch would conflict with injecting optflags). I propose just removing it with sed within %ifarch. Attaching an updated dist-git patch.

Comment 6 Rex Dieter 2016-04-05 13:54:29 UTC
Thanks, adapted a bit and committed,

http://pkgs.fedoraproject.org/cgit/rpms/qt.git/commit/?id=593e8b6cfd804fabbc3e79fdccd2a5adad8f145c

builds underway.

Comment 7 Fedora Update System 2016-04-15 02:30:38 UTC
qt-4.8.7-14.fc24 has been submitted as an update to Fedora 24. https://bodhi.fedoraproject.org/updates/FEDORA-2016-d3a880fb8c

Comment 8 Fedora Update System 2016-04-15 23:22:23 UTC
qt-4.8.7-14.fc24 has been pushed to the Fedora 24 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2016-d3a880fb8c

Comment 9 Fedora Update System 2016-04-15 23:36:12 UTC
qt-4.8.7-15.fc24 has been submitted as an update to Fedora 24. https://bodhi.fedoraproject.org/updates/FEDORA-2016-d3a880fb8c

Comment 10 Fedora Update System 2016-04-18 04:56:09 UTC
qt-4.8.7-15.fc24 has been pushed to the Fedora 24 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2016-d3a880fb8c

Comment 11 Fedora Update System 2016-04-19 20:31:19 UTC
qt-4.8.7-15.fc24 has been pushed to the Fedora 24 stable repository. If problems still persist, please make note of it in this bug report.

Comment 12 Jan Kurik 2016-07-26 04:58:19 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 25 development cycle.
Changing version to '25'.

Comment 13 Rex Dieter 2016-12-05 13:54:24 UTC
marking fixed


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