Am 18.10.2016 um 02:29 schrieb Jack:
> On 2016.10.17 02:44, Ralf Habacker wrote:
>> Am 17.10.2016 um 00:52 schrieb Jack:
>> > Something Alan sent me made me look and think it might have been
>> > because alkimia was compiled with qt5, but I'm no longer sure about
>> that.
>> alkimia >= 5.0.0 fetches Qt5 dependencies into a project using it. You
>> need to revert alkimia to  version <= 4.3.2. Another option would be to
>> (re)add Qt4 support to recent alkimia.
>> Ralf
> Well, that does explain it.  I have two versions, but both are too
> recent.
> I think re-adding Qt4 support would be good.  Unfortunately, we're not
> quite ready to be completely without it yet, so I suspect it might be
> the least painful option.
> Is that something easily done with a change to CMakeLists.txt, or is
> it more involved?
If you do not need to coinstall Qt4 variant along with Qt5 this need to
be done:

1. add a cmake configure option e.g. BUILD_QT4 or similar to enable
building for Qt4.
2. find Qt4 instead of Qt5
3. replace references to Qt5 by related Qt4 ones
3.1. all CMakeLists.txt e.g. Qt5::Core by Qt4::QtCore and similar
3.2. in src/ (see find_dependency)
3.3. in src/ (replace reference to Qt5Core, Qt5DBus by
QtCore, QtDBus)

To have a Qt4 based binary package coinstalled with Qt5 the following
stuff need to be changed too:
4. Install cmake configuration files into different sub dir  (Qt5:
LibAlkimia-<version>)  e.g.  LibAlkimiaQt4-<version>
5. Create different pkgconfig file e.g. libalkimiaQt4.pc or similar
6. Create different libalkimia shared object file  e.g. using set_target_properties (... OUTPUT_NAME)
7. Install header files into a separate sub dir to not be overwritten by
Qt5 installation e.g. /usr/include/alkimia-qt4 or similar (there may be
a distribution standard for that, I don't know)

8. Patch kmymoney in branch 4.8 to use the Qt4 alkimia version.


Reply via email to