FreeBSD 6.x
From Compiz
Contents |
ATI Radeon
su - root password: ********
Configuring kernel
add in your kernel config:
device agp device drm device radeondrm device acpi
compile and install your new kernel or just do following:
kldload agp kldload acpi kldload drm kldload radeondrm
Installing required ports
cvsup your ports and install required software
cd /usr/ports/x11/xorg && make install clean cd /usr/ports/x11/gnome2 && make install clean # probably will require two days ;) cd /usr/ports/x11/libXtrans && make install clean cd /usr/ports/x11-toolkits/open-motif && make install clean cd /usr/ports/devel/gnu-autoconf && make install clean cd /usr/ports/devel/gnu-automake && make install clean cd /usr/ports/devel/libtool15 && make install clean
add to your PATH /usr/local/gnu-autotools/bin or do following:
ln -s /usr/local/gnu-autotools/bin/aclocal /usr/local/bin/aclocal ln -s /usr/local/gnu-autotools/bin/autoconf /usr/local/bin/autoconf ln -s /usr/local/gnu-autotools/bin/autoheader /usr/local/bin/autoheader ln -s /usr/local/gnu-autotools/bin/autom4te /usr/local/bin/autom4te ln -s /usr/local/gnu-autotools/bin/automake /usr/local/bin/automake ln -s /usr/local/gnu-autotools/bin/autoreconf /usr/local/bin/autoreconf ln -s /usr/local/gnu-autotools/bin/autoscan /usr/local/bin/autoscan ln -s /usr/local/gnu-autotools/bin/autoupdate /usr/local/bin/autoupdate ln -s /usr/local/gnu-autotools/bin/ifnames /usr/local/bin/ifnames
cp /usr/local/share/aclocal/*.m4 /usr/local/gnu-autotools/share/aclocal cp /usr/X11R6/share/aclocal/*.m4 /usr/local/gnu-autotools/share/aclocal
Installing Xgl/Compiz from sources
mkdir /opt mkdir /opt/fdo mkdir /opt/fdo/SRC
cd /opt/fdo/SRC
Login to CVS
cvs -d :pserver:anoncvs@cvs.freedesktop.org:/cvs/xorg login password: <hit enter>
util/macros
cd /opt/fdo/SRC cvs -z3 -d :pserver:anoncvs@cvs.freedesktop.org:/cvs/xorg co util/macros cd util/macros ./autogen.sh --prefix=/usr/X11R6 && gmake && gmake install cp /usr/X11R6/share/aclocal/xorg* /usr/local/gnu-autotools/share/aclocal
X11/proto
cd /opt/fdo/SRC cvs -z3 -d :pserver:anoncvs@cvs.freedesktop.org:/cvs/xorg co proto cd /opt/fdo/SRC/proto for i in */; do cd $i; ./autogen.sh --prefix=/usr/X11R6 && gmake && gmake install; cd ..; done
libdrm
cd /opt/fdo/SRC cvs -z3 -d :pserver:anoncvs@cvs.freedesktop.org:/cvs/dri co drm cd drm ./autogen.sh && gmake && gmake install
glitz
cd /opt/fdo/SRC cvs -z3 -d :pserver:anoncvs@cvs.freedesktop.org:/cvs/cairo co glitz cd glitz ./autogen.sh --prefix=/usr/local && gmake && gmake install
Mesa GL
cd /opt/fdo/SRC cvs -z3 -d :pserver:anoncvs@cvs.freedesktop.org:/cvs/mesa co Mesa cd Mesa cd configs ln -s freebsd-dri-x86 current cd ..
SEE NOTE
gmake && gmake install
script will ask you where includes and libs should be installed, type /usr/X11R6/include , hit enter, and then /usr/X11R6/lib , then hit enter again
echo "MKLIB_OPTIONS = -static " >> configs/freebsd-dri gmake && gmake install
NOTE: you might have to add
GLvector4f *PointSizePtr; /* _TNL_BIT_POS */
to file /opt/fdo/SRC/Mesa/src/mesa/tnl/t_context.h, in structure vertex_buffer (line 393)
Compiz
cd /opt/fdo/SRC cvs -z3 -d :pserver:anoncvs@cvs.freedesktop.org:/cvs/xorg co app/compiz cd app/compiz CFLAGS="-I/usr/X11R6/include -I/usr/local/include" \ LDFLAGS="-L/usr/X11R6/lib -L/usr/local/lib" \ COMPIZ_CFLAGS=" -I/usr/X11R6/include/startup-notification-1.0" \ COMPIZ_LIBS="-lstartup-notification-1 -lXext -lXxf86vm -lpng -lXcomposite -lXrandr" \ GNOME_WINDOW_DECORATOR_CFLAGS=" \ -I/usr/X11R6/include/gtk-2.0 \ -I/usr/local/include/cairo \ -I/usr/local/include/glib-2.0 \ -I/usr/X11R6/include/pango-1.0 \ -I/usr/local/include/atk-1.0 \ -I/usr/X11R6/include/gconf/2 \ -I/usr/X11R6/include/libwnck-1.0 \ " \ GNOME_WINDOW_DECORATOR_LIBS="-lgtk-x11-2.0 -lcairo -lwnck-1 -lgconf-2 -lglitz" \ GNOME_WINDOW_SETTINGS_CFLAGS=" \ -I/usr/X11R6/include/gconf/2 \ -I/usr/local/include/glib-2.0 \ -I/usr/X11R6/include/gnome-window-settings-2.0 \ -I/usr/X11R6/include/gnome-desktop-2.0 \ -I/usr/X11R6/include/gtk-2.0 \ -I/usr/local/include/cairo \ -I/usr/X11R6/include/pango-1.0 \ -I/usr/X11R6/include/libgnome-2.0 \ -I/usr/X11R6/include/libgnomeui-2.0 \ " \ GCONF_CFLAGS="-I/usr/X11R6/include/gconf/2 -I/usr/local/include/glib-2.0" \ GCONF_LIBS="-lgconf-2" \ LIBSVG_CAIRO_CFLAGS="-I/usr/local/include -I/usr/local/include/cairo" \ LIBSVG_CAIRO_LIBS="-lsvg-cairo -lcairo -L/usr/local/lib" \ ./autogen.sh --prefix=/opt/fdo --with-gl-libs="-lGL -ldrm -pthread" \ gmake && gmake install
NOTE: Some people were able to compile it using this line
./autogen.sh --prefix=/opt/fdo --build="i386-portbld-freebsd6.0" --host="i386-portbld-freebsd6.0" --with-gl-libs="-lGL -ldrm -pthread" \
instead of
./autogen.sh --prefix=/opt/fdo --with-gl-libs="-lGL -ldrm -pthread" \
In the above code.
lib/xtrans
cd /opt/fdo/SRC cvs -z3 -d :pserver:anoncvs@cvs.freedesktop.org:/cvs/xorg co lib/xtrans cd lib/xtrans ./autogen.sh --prefix=/usr/X11R6 && gmake && gmake install cp /usr/X11R6/share/aclocal/xtrans.m4 /usr/local/gnu-autotools/share/aclocal
Xgl
cd /opt/fdo/SRC cvs -z3 -d :pserver:anoncvs@cvs.freedesktop.org:/cvs/xorg co -r xgl-0-0-1 xserver cd xserver/xorg
sed -i -E 's/@APP_MAN_SUFFIX@/man/g' doc/Makefile.am
CFLAGS="-I/usr/X11R6/include -I/usr/local/include" \ XLIB_CFLAGS="-I/usr/X11R6/include" \ XLIB_LIBS="-lX11 -L/usr/X11R6/lib" \ GL_CFLAGS="-I/usr/X11R6/include" \ GL_LIBS="-lGL -L/usr/X11R6/lib" \ DRIPROTO_CFLAGS="-I/usr/X11R6/include/X11/dri" \ DRIPROTO_LIBS="-L/usr/X11R6/lib" \ XSERVERLIBS_CFLAGS="-I/usr/X11R6/include" \ XSERVERLIBS_LIBS=" -lxkbfile -lXxf86misc -lXxf86vm -lXaw -lXmu -lXt \ -lXpm -lXext -lX11 -L/usr/X11R6/lib" \ XSERVERCFLAGS_CFLAGS="-I/usr/X11R6/include/extensions" \ XSERVERCFLAGS_LIBS="-lxkbfile -lXfont -lXau -lfontenc -L/usr/X11R6/lib" \ XORGCONFIG_DEP_CFLAGS="-I/usr/X11R6/include" \ XORGCONFIG_DEP_LIBS="-lxkbfile -lX11 -L/usr/X11R6/lib" \ XORGCFG_DEP_CFLAGS="-I/usr/X11R6/include" \ XORGCFG_DEP_LIBS="-lxkbui -lxkbfile -lXxf86misc -lXxf86vm -lXaw -lXmu -lXt \ -lXpm -lXext -lX11 -L/usr/X11R6/lib" \ XGLMODULES_CFLAGS="-I/usr/X11R6/include -I/usr/local/include" \ XGLMODULES_LIBS="-lglitz -lXfont -lfreetype -lfontconfig -lfntstubs -lXrender \ -lXrandr -lXau -lxkbfile -L/usr/X11R6/lib -L/usr/local/lib" \ XGLXMODULES_CFLAGS="-I/usr/X11R6/include -I/usr/local/include" \ XGLXMODULES_LIBS="-lglitz-glx -ldrm -lXfont -lfontconfig -lfreetype -L/usr/X11R6/lib -L/usr/local/lib" \ FREETYPE_CFLAGS="-I/usr/local/include" \ FREETYPE_LIBS="-lfreetype -L/usr/local/lib" \ ./autogen.sh --enable-xgl --disable-xorg --disable-xprint --enable-glx \ --enable-dri --with-mesa-source=/opt/fdo/SRC/Mesa \ --with-release-snap=1 --disable-dmx --disable-xvfb \ --disable-xnest --enable-xglx --enable-xkb \ --disable-kdriveserver --prefix=/opt/fdo --disable-builddocs && \ gmake && gmake install
Starting Xgl/Compiz
ln -s /usr/X11R6/lib/X11 /opt/fdo/lib/X11
edit /usr/X11R6/share/gnome/gdm/defaults.conf, comment line 527
0=Standard
edit /usr/X11R6/etc/gdm/custom.conf add following at end of file:
[servers] 1=Xgl
[server-Xgl] command=/opt/fdo/bin/Xgl :1 -fullscreen -ac -accel glx:pbuffer -ac -accel xv:pbuffer name=Xgl server flexible=true chooser=false handled=true priority=0
edit /etc/ttys: replace ttyv8 record with following:
ttyv8 "/usr/X11R6/sbin/gdm -nodaemon" xterm on secure
restart gdm
/usr/X11R6/sbin/gdm-stop /usr/X11R6/sbin/gdm
If gdm does not stop, try the following commands
kill -1 1 killall gdm-binary # do this until `ps -ax | grep Xgl` will show result
after Xgl successfully started log in your gnome session and run following:
DISPLAY=:1 /opt/fdo/bin/gnome-window-decorator & DISPLAY=:1 /opt/fdo/bin/compiz --replace gconf &
to switch between Xgl and Xorg just replace 1=Xgl within 0=Standard in your /usr/X11R6/etc/gdm/custom.conf
NVIDIA
Discussions
Author
Denis F. Latypoff [funky] -- latypoff at yandex.ru
(with minor contributions from others)