Peter's Solaris Zone

Building XFCE on Solaris 10

The following details what I needed to do to install XFCE on a Solaris 10 machine. Specifically, S10 update 6 on x86.

First download the source tarball. This contains a bunch of other tarballs that need to be unpacked.

Basic build

Assuming you want to have the files end up in a directory tree rooted at $PREFIX, then the basic algorithm for each component is:

setenv PKG_CONFIG_PATH $PREFIX/lib/pkgconfig:/usr/lib/pkgconfig
env PATH=$PREFIX/bin:/usr/bin:/usr/sfw/bin:$PATH ./configure --prefix=$PREFIX
env PATH=$PREFIX/bin:/usr/bin:/usr/sfw/bin:$PATH gmake
env PATH=$PREFIX/bin:/usr/bin:/usr/sfw/bin:$PATH gmake -k install

I generally use a parallel make (gmake -j 4). The install needs gmake -k in many cases, sometimes some odd bit of documentation won't build and you don't want that stopping it installing half the files you need.

Dependencies

There are a whole load of dependencies that you need, basically updated versions of the ones that come with Solaris 10. If you don't do the prerequisites, then you're in for a life of pain.

pkg-config-0.23
glib-2.20.4
atk-1.26.0
pixman-0.15.14
pango-1.24.4
cairo-1.8.8
gtk+-2.16.4
gettext-0.14.5
startup-notification-0.9
dbus-1.2.14
dbus-glib-0.80
intltool-0.40.6

To build atk you'll need to set LD_LIBRARY_PATH:

env LD_LIBRARY_PATH=$PREFIX/lib PATH=$PREFIX/bin:/usr/bin:/usr/sfw/bin:$PATH ./configure --prefix=$PREFIX

To build gtk+ you'll need to set LD_LIBRARY_PATH and a little extra tweak:

env LD_LIBRARY_PATH=$PREFIX/lib PATH=$PREFIX/bin:/usr/bin:/usr/sfw/bin:$PATH ./configure --prefix=$PREFIX --without-libjasper

For dbus I had to work a little harder:

env LDFLAGS="-L/usr/sfw/lib -R/usr/sfw/lib" CPPFLAGS="-I/usr/sfw/include" CC=cc CXX=CC PATH=$PREFIX/bin:/usr/bin:/usr/sfw/bin:$PATH ./configure --prefix=$PREFIX

The intltool build messes up its include flags. The simplest way I found to get round this was:

cd $PREFIX/include/cairo/
ln -s . cairo

The XFCE build

The individual components for 4.6.1 are:

xfce4-dev-tools-4.6.0
libxfce4util-4.6.1
xfconf-4.6.1
libxfcegui4-4.6.1
libxfce4menu-4.6.1
exo-0.3.101
xfce4-panel-4.6.1
Thunar-1.0.1
xfce4-settings-4.6.1 *
xfce4-session-4.6.1
xfdesktop-4.6.1
xfwm4-4.6.1
xfwm4-themes-4.6.0
xfce-utils-4.6.1
xfce4-mixer-4.6.1 **
xfprint-4.6.1
xfce4-appfinder-4.6.1
gtk-xfce-engine-2.6.0
mousepad-0.2.16
Terminal-0.2.12
orage-4.6.1

They need to be built in the above order, after all the prerequisites.

Thunar won't compile - DEFFILEMODE undeclared. The fix for bug 3532 is broken, but simply replace DEFFILEMODE by 0666 in thunar-vfs/thunar-vfs-io-jobs.c

xfce4-settings wants xi. Oh, it's libXi. But the pkg-config check will just never work. And it uses the same check for libX11. Creating xi.pc and x11.pc files seems the only way to defeat it. My $PREFIX/lib/pkgconfig/xi.pc looks like:

prefix=/usr
exec_prefix=${prefix}
libdir=${exec_prefix}/lib
includedir=${exec_prefix}/include

Name: Xi
Description: X Input Extension Library
Version: 1.0.0
Libs: -lXi

and for x11 that's $PREFIX/lib/pkgconfig/x11.pc

prefix=/usr
exec_prefix=${prefix}
libdir=${exec_prefix}/lib
includedir=${exec_prefix}/include

Name: X11
Description: X Library
Version: 1.0.0
Libs: -lX11

I found in addition that xfce4-setting should also have --disable-libxklavier added to the configure command.

xfce4-mixer won't work; I'm not going to try hacking gstreamer into shape to fix it either.

Once built, it wouldn't start. The startup scripts aren't bourne shell compatible, so need to be launched with bash. (Or fixed properly. But the simplest fix is to edit the line in $PREFIX/bin/startxfce4 that says "prog=/bin/sh" with "prog=/bin/bash". I've submitted a patch that will fix the underlying issue so later versions should be fine.)

Settings doesn't work. libxfcegui4 tries to put glade files in the system locations, which won't work. So, from you build root:

cp libxfcegui4-4.6.1/glade/.libs/libxfce4.so $PREFIX/lib

Goodies

ristretto; needs updated libexif. Unfortunately the ristretto compile is busted. In src/Makefile, THUNAR_VFS_LIBSS needs -R$PREFIX/lib -lint -lX11 added.

xfce4-screenshooter - is actually pretty neat; a worthy replacement at last for sdtimage

xfce4-taskmanager - needs -R$PREFIX/lib adding to LIBXFCEGUI4_LIBS in src/Makefile. Doesn't work under Solaris at all, however.


Peter's Home | Zone Home