Add yourself to the relicense checker script

From the KDE relicensing page:

A couple of KDE dependent projects or even libraries have moved or are going to move to GPLv3.

Unfortunately, GPL v3 is incompatible with GPL v2. This means that it is not possible to create a project linking GPL v2 and v3 code together. There is no problem for projects which are licensed GPLv2+ (version 2 or above).

A few parts of KDE are currently licensed as GPLv2 only. So far we have no reason to believe that this was something other than an oversight. However, we still need to validate with the individual copyright holders that a relicense to GPLv2+ or GPLv2+v3 is okay with them.

Therefore, in an effort we’re trying to identify the contributors that have contributed under the terms of GPLv2 and where the “+” part was not explicitly mentioned. If we know that all contributors agreed to a relicense, we can go ahead and flip the license of the individual source file.

Short story: If you have not done so yet, please add yourself to the kde relicensecheck.pl file!

Kate5 on Mac

Given that the KF5 based Kate works OK on Windows, I would like to get the Mac version up and running, too.

As virtualization of MacOS X is kind of “forbidden” and not that nicely usable anyway, as no nice accelerating drivers are available for the standard vm solutions, I just went out into the world and bought some Retina MacBook.

I followed the nice guide on https://github.com/haraldF/homebrew-kf5 (thanks Harald :=) and got some installed Kate/KWrite (after patching kio to skip X11 detection).

But ok, not that usable, at least without any investigation which env vars are missing per default you get a Kate that crashs or just shows the main window central content without any actions/menus/toolbars/sidebars/…

In addition, the application is scaled, as the manifest that tells we are able to handle retina bla stuff is missing.

Guess lots of work ahead, but given I have now some Mac, I will work on that in the following months ;)

P.S. I never had a Mac before and got often told by “Mac Fans” that I should switch to some “real” operating system from my stupid borked unusable cluttered hacky … Linux. Given that the new shiny MacBook directly stalled for ever during the guided “create your user and give us all your data” installation wizard on first boot, I am not that impressed ;=) My mother would have been stuck and after some googling that seems to be a “known issue”, at least for me, after a hard reboot, the thingy worked and I had a login, more luck than others :P

Qt 5.4 on Red Hat Enterprise 5

For my job, I need to take care of the support of old Linux distributions for our products, therefore I experimented in building Qt 5.x for Red Hat Enterprise 5 (or CentOS 5 or other clones).

Whereas Red Hat Enterprise 6 works more or less out of the box, to build Qt (even with WebKit and Co.) on Red Hat Enterprise 5, more work is needed. Even the xcb library is not yet existent there.

Therefore, here a small howto, for other people having problems with building it. It contains some hacks and any input is for sure nice to have as an comment (to help others to avoid my faults).

Disclaimer: I am not responsible for creating a completely messy and buggy Qt 5.x build :=)

First, lets assume you have some CentOS 5.11 box or chroot.

You will need some new development toolsets to get rolling:

wget http://people.centos.org/tru/devtools-1.1/devtools-1.1.repo -O /etc/yum.repos.d/devtools-1.1.repo
wget http://people.centos.org/tru/devtools-2/devtools-2.repo -O /etc/yum.repos.d/devtools-2.repo

I tend to use the version 2, version 1.1 does work, too (GCC 4.7.2 vs. 4.8.2).

We will needed EPEL, for a more up-to-date python (2.6, for xcb):

wget http://ftp.tu-chemnitz.de/pub/linux/fedora-epel/5/x86_64/epel-release-5-4.noarch.rpm
rpm -i epel-release-5-4.noarch.rpm

Then, lets install the minimal deps (I install both toolsets, you can choose one):

yum install devtoolset-1.1 devtoolset-2 python26 fontconfig-devel libX11-devel libXau-devel libXext-devel libXrender-devel

Then, get some compile shell ready:

scl enable devtoolset-2 bash

I will just for excercise build Qt and stuff into /tmp/usr/(qt)?

To build Qt, you need libxcb, get that (with deps):

# package config for xcb stuff
export PKG_CONFIG_PATH=/tmp/usr/lib/pkgconfig

# xcb proto
wget http://xcb.freedesktop.org/dist/xcb-proto-1.11.tar.gz
tar -xzf xcb-proto-1.11.tar.gz
cd xcb-proto-1.11
./configure –prefix=/tmp/usr
make -j8
make install
cd ..

# pthread stubs
wget http://xcb.freedesktop.org/dist/libpthread-stubs-0.3.tar.gz
tar -xzf libpthread-stubs-0.3.tar.gz
cd libpthread-stubs-0.3
./configure –prefix=/tmp/usr
make -j8
make install
cd ..

# xcb
wget http://xcb.freedesktop.org/dist/libxcb-1.11.tar.gz
tar -xzf libxcb-1.11.tar.gz
cd libxcb-1.11
./configure –prefix=/tmp/usr
make -j8
make install
cd ..

Now we are ready to build Qt 5.4, at least some parts ;=)
I skip here the GL stuff, I don’t need it and I skip some other modules.

# unpack qt
tar -xzf qt-everywhere-opensource-src-5.4.0.tar.gz
cd qt-everywhere-opensource-src-5.4.0

# no perf events => patch that out, won’t compile, at least not for me because of missing syscall/broken kernel header
sed -i “s/#define QTESTLIB_USE_PERF_EVENTS/#undef QTESTLIB_USE_PERF_EVENTS/g” qtbase/src/testlib/qbenchmark_p.h

# configure with some defines to work on centos 5 (fake some defines)
./configure -R ‘\\\$$ORIGIN’ -D _X_INLINE=inline -D XK_dead_currency=0xfe6f -D XK_ISO_Level5_Lock=0xfe13 -D FC_WEIGHT_EXTRABLACK=215 -D FC_WEIGHT_ULTRABLACK=FC_WEIGHT_EXTRABLACK -v -opensource -confirm-license -sysconfdir /etc/xdg -prefix /tmp/usr/qt -release -shared -qt-zlib -qt-libpng -qt-libjpeg -qt-pcre -qt-xcb -qt-xkbcommon -xkb-config-root /usr/share/X11/xkb -no-xcb-xlib -c++11 -nomake examples -nomake tests -no-dbus -no-icu -no-opengl -skip activeqt -skip androidextras -skip connectivity -skip enginio -skip location -skip macextras -skip multimedia -skip quick1 -skip sensors -skip serialport -skip wayland -skip webchannel -skip webengine -skip webkit -skip webkit-examples -skip websockets -skip winextras -skip x11extras

# build and install
make -j8
make install

=> You have some Qt, but keep in mind you need to bundle at least the libxcb.so* library, as your Red Hat Enterprise 5.x guys won’t have it!