1 These instructions assume some familiarity with git and building and
2 running experimental software. And be prepared that this project
3 isn't at all useful right now, it's still very much a prototype. When
4 the instructions suggest to clone a git repo, you can of course just
5 add a remote and fetch instead, if you have a clone of that repo
6 around already. I usually install all software I'm working on into
7 $HOME/install, so that's what I'll use in the instructions below, but
8 you can use your favorite directory of course or install over your
9 system copy (pass --prefix=/usr --sysconfdir=/etc, generally).
14 At this point, kernel modesetting is upstream for Intel, AMD and
15 nVidia chipsets. Most distributions ship with kernel modesetting
16 enabled by default and will work with Wayland out of the box. The
17 modesetting driver must also support the page flip ioctl, which only
18 the intel driver does at this point.
23 Wayland uses the mesa EGL stack, and all extensions required to run
24 EGL on KMS are now upstream on the master branch. The 7.9 release of
25 mesa will have all these extensions, but for now you'll need to build
28 $ git clone git://anongit.freedesktop.org/mesa/mesa
30 $ ./configure --prefix=$HOME/install --enable-egl --enable-gles2
31 $ make && make install
33 If you're using an intel chipset, it's best to also pass
34 --disable-gallium to ./configure, since otherwise libEGL will try to
35 load the gallium sw rasterizer before loading the Intel DRI driver.
40 Wayland needs libxkbcommon for translating evdev keycodes to keysyms.
41 There's a couple of repos around, and we're trying to consolidate the
42 development, but for wayland you'll need the repo from my get
43 repository. For this you'll need development packages for xproto,
46 $ git clone git://people.freedesktop.org/~krh/libxkbcommon.git
48 $ ./autogen.sh --prefix=$HOME/install
49 $ make && make install
54 The Waland clients render using cairo-gl, which is an experimental
55 cairo backend. It has been available since cairo 1.10. Unless your
56 distribution ships cairo with the gl backend enabled, you'll need to
57 compile your own version of cairo:
59 $ git clone git://anongit.freedesktop.org/cairo
61 $ ./autogen.sh --prefix=$HOME/install --enable-gl
62 $ make && make install
67 With mesa and libxkbcommon in place, we can checkout and build
68 Wayland. Aside from mesa, Wayland needs development packages for
69 gdk-pixbuf-2.0, libudev, libdrm, xcb-dri2, xcb-fixes (for X
70 compositor) cairo-gl, glib-2.0, gdk-2.0 (for poppler) and
73 $ git clone git://people.freedesktop.org/~krh/wayland
74 $ aclocal; autoconf; ./configure --prefix=$HOME/install
75 $ make && make install
77 Installing into a non-/usr prefix is fine, but the 70-wayland.rules
78 udev rule file has to be installed in /etc/udev/rules.d. Once
79 installed, either reboot or run
81 $ sudo udevadm trigger --subsystem-match=drm --subsystem-match=input
83 to make udev label the devices wayland will use.
85 If DISPLAY is set, the wayland compositor will run under X in a window
86 and take input from X. Otherwise it will run on the KMS framebuffer
87 and take input from evdev devices. Pick a background image that you
88 like and copy it to the Wayland source directory as background.jpg or
89 use the -b command line option:
91 $ ./wayland-system-compositor -b my-image.jpg
93 To run clients, switch to a different VT and run the client from
94 there. Or run it under X and start up the clients from a terminal
95 window. There are a few demo clients available, but they are all
96 pretty simple and mostly for testing specific features in the wayland
97 protocol: 'terminal' is a simple terminal emulator, not very compliant
98 at all, but works well enough for bash
100 'flower' moves a flower around the screen, testing the frame protocol
101 'gears' glxgears, but for wayland, currently broken
102 'image' loads the image files passed on the command line and shows them
104 'view' does the same for pdf files, but needs file URIs
105 (file:///path/to/pdf)