Bug 17039 - Build qscintilla with qt4 and qt5 and allow parallel install
Summary: Build qscintilla with qt4 and qt5 and allow parallel install
Status: RESOLVED FIXED
Alias: None
Product: Mageia
Classification: Unclassified
Component: RPM Packages (show other bugs)
Version: Cauldron
Hardware: All Linux
Priority: Normal normal
Target Milestone: ---
Assignee: Matteo Pasotti
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-10-28 16:50 CET by Nicolas Salguero
Modified: 2016-02-22 11:21 CET (History)
4 users (show)

See Also:
Source RPM:
CVE:
Status comment:


Attachments
A patch from Linux From Scratch to allow parallel install (3.62 KB, patch)
2015-10-29 15:25 CET, Nicolas Salguero
Details | Diff
A patch to qscintilla.spec (6.80 KB, patch)
2015-10-29 15:28 CET, Nicolas Salguero
Details | Diff
qscintilla.spec.diff (1.96 KB, patch)
2015-11-10 09:35 CET, David GEIGER
Details | Diff

Description Nicolas Salguero 2015-10-28 16:50:05 CET
Hi,

Currently qscintilla is only built with qt5 so all the packages that need qscintilla built with qt4 fail to build (smokeqt, ruby-qt4, tora...).

I found that fedora is able to build qscintilla with qt4 and qt5 and allow parallel install.

Could not we do the same thing to allow the packages that need qscintilla built with qt4 to build again?

Best regards,

Nico.
Comment 1 Nicolas Salguero 2015-10-29 15:25:56 CET
Created attachment 7173 [details]
A patch from Linux From Scratch to allow parallel install
Comment 2 Nicolas Salguero 2015-10-29 15:28:58 CET
Created attachment 7174 [details]
A patch to qscintilla.spec
David Walser 2015-10-30 15:39:55 CET

Assignee: bugsquad => matteo.pasotti

Comment 3 Nicolas Salguero 2015-10-31 12:07:19 CET
Hi,

To sum up my tests:

1) With the patch from Linux From Scratch which allow parallel
installation and my modifications in qscintilla.spec, I was able to
locally obtain the following packages:
   - For Qt4: qscintilla-i18n, lib64qscintilla2_12,
lib64qscintilla-devel and python-qt4-qscintilla.
   - For Qt5: qscintilla-qt5-i18n, lib64qt5scintilla2_12,
lib64qt5scintilla-devel and python3-qt5-qscintilla.

2) The packages which require qscintilla-qt4-devel can now be built
again (I tested with smokeqt, ruby-qt4 and tora) and are linked to
Qscintilla with Qt4 without modification to SPEC files.

3) The packages which require qscintilla-qt5-devel need a rebuild
(because, for Qt5, library is now named libqt5scintilla2.so.12 and
libqscintilla2.so.12 is used for Qt4 version) and I was able to locally
build openscad without modification to SPEC file.

Renaming the library to that manner seems rather common because
openscad.prf file already contains a condition saying that, if
QT_MAJOR_VERSION is greater than 4, then the library is qt5scintilla2
else the library is qscintilla2.

I could submit myself the modifications to qscintilla if needed but I will not do that without KDE stack maintainers' approval.

Best regards,

Nico.
Comment 4 Rémi Verschelde 2015-10-31 13:00:52 CET
CC'ing neoclust and lmenut for comment 3.

CC: (none) => lmenut, mageia

Comment 5 Nicolas Salguero 2015-11-03 10:46:58 CET
As qt4-devel does not require phonon-devel anymore, we will have to add phonon-devel build requirement to smokeqt.
Comment 6 Rémi Verschelde 2015-11-09 08:09:13 CET
@Nicolas Salguero: Nicolas Lécureuil (neoclust) has done some work on qscintilla to enable it for both Qt4 and Qt5 and both python2 and python3. Then I did some cleanup of the spec, could you now compare it with your changes and maybe improve if need be? We haven't really heard from Matteo on this matter so feel free to change things as you see best fit.

I managed to build eric6 against the new python3-qt5-qscintilla, but it looks like there is still something wrong for smokeqt (it doesn't locate qscintilla).
Comment 7 David GEIGER 2015-11-09 10:08:03 CET
I have more cleaned spec file and also fixed an incorrect requires on lib(64)qscintilla2-devel subpackage. :)

s/Requires: %{libqs5} = %{version}-%{release}/Requires: %{libqs4} = %{version}-%{release}

But not submitted for now.

CC: (none) => geiger.david68210

Comment 8 Rémi Verschelde 2015-11-09 10:19:44 CET
Nice catch, this might have been the reason why smokeqt does not build.

There is still one likely issue that I see in the spec:

%files -n %{libqs5dev}
--> %{_includedir}/Qsci
--> %{_qt5_includedir}/*
%{_qt5_libdir}/libqscintilla2-qt5.so
%{_qt5_prefix}/mkspecs/features/qscintilla2.prf
%{_qt5_plugindir}/designer/*

%files -n %{libqs4dev}
%{_qt4_prefix}/mkspecs/features/qscintilla2.prf
%{_qt4_libdir}/libqscintilla2.so
%{_qt4_plugindir}/designer/libqscintillaplugin.so


It seems like the %libqs5dev package holds all headers, so the %libqs4dev package is probably broken right now. The %libqs4dev package probably needs %{_includedir}/Qsci.
I don't know though if the &libqs5dev package also needs it (if so it would have to be split into a package that both dev libs could depend on), or if %{_qt5_includedir}/* is enough. I suspect the latter (i.e. %{_qt5_includedir}/* might have the same headers than %{_includedir}/Qsci).
Angelo Naselli 2015-11-09 11:15:06 CET

CC: (none) => anaselli

Comment 9 David GEIGER 2015-11-09 16:14:47 CET
@Nicolas Salguero:

Can you replace BuildRequires: python3-qt4, please?

s/BuildRequires: python3-qt4/BuildRequires: python3-qt4-devel/
Comment 10 Rémi Verschelde 2015-11-09 16:18:09 CET
(In reply to David GEIGER from comment #9)
> @Nicolas Salguero:
> 
> Can you replace BuildRequires: python3-qt4, please?
> 
> s/BuildRequires: python3-qt4/BuildRequires: python3-qt4-devel/

No need for a rebuild afterwards though, it doesn't impact the end package.
Comment 11 Nicolas Salguero 2015-11-09 16:20:37 CET
Too late :-(

Sometimes I feel like Lucky Luke.
Comment 12 David GEIGER 2015-11-10 09:35:23 CET
Created attachment 7192 [details]
qscintilla.spec.diff

@ Rémi:

maybe obsoleting something like the attached patch.
Comment 13 Nicolas Salguero 2016-02-22 11:21:10 CET
Hi,

The problem was solved since several months but I forgot to close the bug report.

Best regards,

Nico.

Status: NEW => RESOLVED
Resolution: (none) => FIXED


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