(fixed, please use talk page in the future) |
(→setup for SSH) |
||
| Line 25: | Line 25: | ||
yast -i libmysqlclient-devel libmysqld-devel cmake libical-devel git cyrus-sasl-devel libredland-devel \ | yast -i libmysqlclient-devel libmysqld-devel cmake libical-devel git cyrus-sasl-devel libredland-devel \ | ||
| − | libqt4-devel | + | libqt4-devel docbook-xsl-stylesheets |
;Now it is time to do a snapshot or clone from your VM. | ;Now it is time to do a snapshot or clone from your VM. | ||
This describes the potential of using a virtual machine to contain development, for testing system level KDE tools like KDM without mucking up the rest of your system. Also, virtual machine snapshots can be shared with casual developers so they can have an up to date, rich environment for their minor fixes.
In the included example, a person sets up KDE trunk on a Suse 11.3 Linux Virtual Machine.
Basically nothing special except using root account directly.. And it is in a virtual machine, Note that the build requirements are moving targets so examples are all but useless.
We use KVM because it is faster than other free alternatives, and can use multiple processors (You will need to have a CPU that supports virtualization, cheapernewer computers have cpus that dont advertise if they have this feature or not so you may need to do some homework)
Contents |
Create a KVM virtual machine. KDE 4 fits into 10 GB minimum, I recommend 40GB, one partition. As much ram as you can spare, You will need at least 1GB ram for the virtual machine, 4 doesnt hurt if you have it, install SUSE Linux 11.3.
To be able to log in to your VM using ssh, stop and disable the firewall:
rcSuSEfirewall2 stop chkconfig SuSEfirewall2_setup off chkconfig SuSEfirewall2_init off /etc/init.d/sshd start
Inside the VM, install some needed packages:
yast -i libopenssl-devel subversion gcc-c++ boost-devel libbz2-devel libxml2-devel pcre-devel \ libxslt-devel giflib-devel libjpeg-devel libgpgme-devel xorg-x11-devel glib2-devel libpng-devel \ make dbus-1-devel taglib-devel
yast -i libmysqlclient-devel libmysqld-devel cmake libical-devel git cyrus-sasl-devel libredland-devel \ libqt4-devel docbook-xsl-stylesheets
You will be able to return to this machine state whenever you want. (you may want to do this again after you have downloaded all the stuff but before you muck with stuff)
The rest assumes you are root, which may not be safe.
su -
If and only if you have a /lib64 path, you are on an x64 distribution. Make sure you have the needed environment variables and alias set by having a file /root/.bashrc.
cat >.bashrc<<EOF export KDEDIR=/usr/local alias cmakekde="cmake . -DCMAKE_INSTALL_PREFIX=\$KDEDIR -DLIB_SUFFIX=64 -DCMAKE_BUILD_TYPE=debugfull && make -j8 && make install" alias cmakekdelibs="cmake ../kdelibs -DCMAKE_INSTALL_PREFIX=\$KDEDIR -DLIB_SUFFIX=64 -DCMAKE_BUILD_TYPE=debugfull && make -j8 && make install" alias makeqt="./configure -dbus -openssl -plugin-sql-mysql -libdir /usr/lib64 -prefix /usr && make -j8 && make install" export QTDIR=/usr EOF
Now activate this file
. /root/.bashrc
Make sure you have the needed environment variables and alias set by having a file /root/.bashrc.
cat >.bashrc<<EOF export KDEDIR=/usr/local alias cmakekde="cmake . -DCMAKE_INSTALL_PREFIX=\$KDEDIR -DCMAKE_BUILD_TYPE=debugfull && make -j8 && make install" alias cmakekdelibs="cmake ../kdelibs -DCMAKE_INSTALL_PREFIX=\$KDEDIR -DCMAKE_BUILD_TYPE=debugfull && make -j8 && make install" alias makeqt="./configure -dbus -openssl -plugin-sql-mysql -prefix /usr && make -j8 && make install" export QTDIR=/usr EOF
Now activate this file
. /root/.bashrc
you will need to use svn://anonsvn.kde.org ) Many of these require ckdemake, so the order of the rest is wrong. If something fails you may need to make clean. Building QT takes a few hours.
cd svn co svn://anonsvn.kde.org/home/kde/trunk/kdesupport cd kdesupport cmakekde
cd git clone git://gitorious.org/phonon/phonon.git cd phonon cmakekde
cd git clone git://gitorious.org/dbusmenu/dbusmenu-qt.git cd dbusmenu-qt cmakekde
cd wget http://www.iodbc.org/downloads/iODBC/libiodbc-3.52.7.tar.gz tar xvzf libiodbc-3.52.7.tar.gz cd libiodbc* ./configure && make -j8 && make install
KDELIBS requires an out-of-source build, that is why it is more complicated to build:
cd svn co svn://anonsvn.kde.org/home/kde/trunk/KDE/kdelibs mkdir kdelibs-build cd kdelibs-build cmakekdelibs
Verify it has been correctly installed - the following must be possible:
kde4-config --prefix /usr/local
cd svn co svn://anonsvn.kde.org/home/kde/trunk/KDE/kdepimlibs cd kdepimlibs cmakekde
cd svn co https://svn.kde.org/home/kde/trunk/KDE/kdebase cd kdebase cmakekde
First allow root login. You will need it as you do not have another login:
sed -i "s/AllowRootLogin.*/AllowRootLogin=true/g" /usr/local/share/config/kdm/kdmrc
Now stop your running display manager:
/etc/init.d/xdm stop
And start your self-compiled display manager:
kdm
To enable automated startup of your kdm, you need to change some SUSE-specific paths in /etc/init.d/xdm:
KDM_BIN=/usr/local/bin/kdm KDM4_BIN=/usr/local/bin/kdm