常见问题常见问题   搜索搜索   会员列表会员列表   团队团队   注册注册    个人资料个人资料   登录查看您的站内信件登录查看您的站内信件   登录登录 

在FreeBSD上实现XGL超眩立体桌面效果的过程

 
发表新文章   这个论题已经被锁定,您不能发表、回复或者编辑文章。    FreeBSD China -> 安装-配置-优化-安全
阅读上一个主题 :: 阅读下一个主题  
作者 留言
哈蜜瓜
道童


注册时间: 2002-10-29
文章: 241

文章发表于: Sun 2006-08-20 10:07:42    发表主题: 在FreeBSD上实现XGL超眩立体桌面效果的过程 引用并回复

摘自:http://wiki.compiz.net/index.php/FreeBSD_6.x

代码:
FreeBSD 6.x
From Compiz
Jump to: navigation, search
Contents
[hide]

    * 1 ATI Radeon
          o 1.1 Configuring kernel
          o 1.2 Installing required ports
          o 1.3 Installing Xgl/Compiz from sources
                + 1.3.1 Login to CVS
                + 1.3.2 util/macros
                + 1.3.3 X11/proto
                + 1.3.4 libdrm
                + 1.3.5 glitz
                + 1.3.6 Mesa GL
                + 1.3.7 Compiz
                + 1.3.8 lib/xtrans
                + 1.3.9 Xgl
          o 1.4 Starting Xgl/Compiz
    * 2 NVIDIA
    * 3 Discussions
    * 4 Author


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/gnome-libs && make install clean # Needed for gnome-config
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/graphics/libsvg-cairo && make install clean
cd /usr/ports/devel/git && 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

ln -s /usr/local/gnu-autotools/share/aclocal-1.9 /usr/local/gnu-autotools/share/aclocal

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 -p /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
git clone git://git.freedesktop.org/git/xorg/util/macros 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 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 && 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 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

gmake MKLIB_OPTIONS=-static && gmake install MKLIB_OPTIONS=-static

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
git clone git://git.freedesktop.org/git/xorg/app/compiz app/compiz
cd app/compiz
COMPIZ_CFLAGS="-DXTHREADS -DXUSE_MTSAFE_API -I/usr/X11R6/include \
   -I/usr/X11R6/include/startup-notification-1.0 -I/usr/local/include/libpng" \
COMPIZ_LIBS="-L/usr/local/lib -L/usr/X11R6/lib -lpng -lz -lm -lXcomposite \
   -lXdamage -lXfixes -lX11 -lXrandr -lICE -lSM -lstartup-notification-1" \
GL_CFLAGS="-I/usr/X11R6/include" \
GL_LIBS="-L/usr/X11R6/lib -lGL -L/usr/local/lib -ldrm -pthread" \
GCONF_CFLAGS="-DORBIT2=1 -D_REENTRANT -I/usr/X11R6/include/gconf/2 \
   -I/usr/local/include/orbit-2.0 -I/usr/local/include/glib-2.0 \
   -I/usr/local/lib/glib-2.0/include" \
GCONF_LIBS="-pthread -L/usr/X11R6/lib -lgconf-2" \
PLACE_CFLAGS="-I/usr/local/include/glib-2.0 -I/usr/local/lib/glib-2.0/include" \
PLACE_LIBS="-L/usr/local/lib -lglib-2.0 -liconv" \
LIBSVG_CAIRO_CFLAGS="-I/usr/local/include -I/usr/local/include/cairo \
   -I/usr/local/include/libxml2" \
LIBSVG_CAIRO_LIBS="-L/usr/local/lib -lsvg-cairo" \
GNOME_WINDOW_DECORATOR_CFLAGS="-DXTHREADS -DXUSE_MTSAFE_API -DORBIT2=1 \
   -D_REENTRANT -I/usr/X11R6/include -I/usr/X11R6/include/gtk-2.0 \
   -I/usr/X11R6/lib/gtk-2.0/include -I/usr/X11R6/include/pango-1.0 \
   -I/usr/local/include/cairo -I/usr/local/include/freetype2 \
   -I/usr/local/include -I/usr/X11R6/include/gconf/2 \
   -I/usr/X11R6/include/libwnck-1.0 -I/usr/local/include/atk-1.0 \
   -I/usr/local/include/glib-2.0 -I/usr/local/lib/glib-2.0/include \
   -I/usr/local/include/orbit-2.0" \
GNOME_WINDOW_DECORATOR_LIBS="-Wl,--rpath -Wl,/usr/local/lib -pthread \
   -L/usr/X11R6/lib -L/usr/local/lib -lXrender -lX11 -lXext -lgtk-x11-2.0 \
   -lgconf-2 -lwnck-1 -lpangocairo-1.0 -lfontconfig -lfreetype -lz" \
GNOME_WINDOW_SETTINGS_CFLAGS="-DXTHREADS -DXUSE_MTSAFE_API -DORBIT2=1 \
   -D_REENTRANT -I/usr/X11R6/include/gnome-window-settings-2.0 \
   -I/usr/X11R6/include/gtk-2.0 -I/usr/X11R6/include/libgnomeui-2.0 \
   -I/usr/X11R6/lib/gtk-2.0/include -I/usr/X11R6/include/pango-1.0 \
   -I/usr/local/include/cairo -I/usr/X11R6/include -I/usr/local/include/freetype2 \
   -I/usr/local/include -I/usr/X11R6/include/libgnome-2.0 \
   -I/usr/X11R6/include/libgnomecanvas-2.0 -I/usr/X11R6/include/gconf/2 \
   -I/usr/X11R6/include/libbonoboui-2.0 -I/usr/X11R6/include/gnome-vfs-2.0 \
   -I/usr/X11R6/lib/gnome-vfs-2.0/include -I/usr/X11R6/include/gnome-keyring-1 \
   -I/usr/X11R6/include/gnome-desktop-2.0 -I/usr/X11R6/include/startup-notification-1.0 \
   -I/usr/local/include/atk-1.0 -I/usr/local/include/glib-2.0 \
   -I/usr/local/lib/glib-2.0/include -I/usr/local/include/libart-2.0 \
   -I/usr/local/include/orbit-2.0 -I/usr/local/include/libbonobo-2.0 \
   -I/usr/local/include/bonobo-activation-2.0 -I/usr/local/include/libxml2" \
GNOME_WINDOW_SETTINGS_LIBS="-Wl,--rpath -Wl,/usr/local/lib -pthread -L/usr/X11R6/lib \
   -lgnome-window-settings -lgnome-desktop-2" \
./autogen.sh --build=i386-portbld-freebsd6.1 --enable-libsvg-cairo \
   --prefix=/opt/fdo --with-gl-libs="-L/usr/X11R6/lib -lGL -L/usr/local/lib -ldrm -pthread" && \
gmake && gmake install


I had to add MSGFMT=/usr/local/bin/msgfmt to get it to gmake

lib/xtrans

cd /opt/fdo/SRC
git clone git://git.freedesktop.org/git/xorg/lib/libxtrans lib/libxtrans
cd lib/libxtrans
./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

XLIB_CFLAGS="-DXTHREADS -DXUSE_MTSAFE_API -I/usr/X11R6/include" \
XLIB_LIBS="-L/usr/X11R6/lib -lX11" \
GL_CFLAGS="-I/usr/X11R6/include" \
GL_LIBS="" \
DRIPROTO_CFLAGS="-I/usr/X11R6/include/X11/dri" \
DRIPROTO_LIBS="" \
LIBDRM_CFLAGS="-I/usr/local/include -I/usr/local/include/drm" \
LIBDRM_LIBS="-L/usr/local/lib -ldrm" \
XDMCP_CFLAGS="-I/usr/X11R6/include" \
XDMCP_LIBS="-L/usr/X11R6/lib -lXdmcp" \
XSERVERCFLAGS_CFLAGS="-DXTHREADS -DXUSE_MTSAFE_API -I/usr/X11R6/include \
   -I/usr/X11R6/include/X11/Xtrans -I/usr/X11R6/include/X11/fonts \
   -I/usr/local/include/freetype2 -I/usr/local/include" \
XSERVERCFLAGS_LIBS="-Wl,--rpath -Wl,/usr/local/lib -L/usr/local/lib \
   -L/usr/X11R6/lib -lxkbfile -lXfont -lfntstubs -lfreetype -lm -lz -lXau -lfontenc \
   -lXdmcp" \
XSERVERLIBS_CFLAGS="-I/usr/X11R6/include -I/usr/X11R6/include/X11/fonts \
   -I/usr/local/include/freetype2 -I/usr/local/include" \
XSERVERLIBS_LIBS="-Wl,--rpath -Wl,/usr/local/lib -L/usr/local/lib \
   -L/usr/X11R6/lib -lXfont -lfntstubs -lfreetype -lm -lz -lXau -lfontenc -lXdmcp" \
DMXMODULES_CFLAGS="-DXTHREADS -DXUSE_MTSAFE_API \
   -I/usr/X11R6/include -I/usr/X11R6/include/X11/fonts \
   -I/usr/local/include/freetype2 -I/usr/local/include" \
DMXMODULES_LIBS="-Wl,--rpath -Wl,/usr/local/lib -L/usr/local/lib \
   -L/usr/X11R6/lib -lXmuu -lXt -lSM -lXext -lX11 -lXrender -lXfont -lfntstubs \
   -lfreetype -lm -lz -lICE -lXau -lXdmcp" \
XNESTMODULES_CFLAGS="-DXTHREADS -DXUSE_MTSAFE_API -I/usr/X11R6/include \
   -I/usr/X11R6/include/X11/fonts -I/usr/local/include/freetype2 \
   -I/usr/local/include" \
XNESTMODULES_LIBS="-Wl,--rpath -Wl,/usr/local/lib -L/usr/local/lib \
   -L/usr/X11R6/lib -lXfont -lfntstubs -lfreetype -lm -lz -lXext -lX11 -lXau -lXdmcp" \
XGLMODULES_CFLAGS="-I/usr/local/include" \
XGLMODULES_LIBS="-L/usr/local/lib -lglitz -lm" \
XGLXMODULES_CFLAGS="-DXTHREADS -DXUSE_MTSAFE_API -I/usr/X11R6/include \
   -I/usr/local/include" \
XGLXMODULES_LIBS="-pthread -L/usr/local/lib -L/usr/X11R6/lib -lglitz-glx \
   -lGL -lXrandr -lXext -lXrender -lX11 -lxkbfile" \
XORGCONFIG_DEP_CFLAGS="-DXTHREADS -DXUSE_MTSAFE_API -I/usr/X11R6/include" \
XORGCONFIG_DEP_LIBS="-L/usr/X11R6/lib -lxkbfile -lX11" \
XORGCFG_DEP_CFLAGS="-DXTHREADS -DXUSE_MTSAFE_API -I/usr/X11R6/include" \
XORGCFG_DEP_LIBS="-L/usr/X11R6/lib -lxkbui -lxkbfile -lXxf86misc -lXxf86vm \
   -lXaw -lXmu -lXt -lSM -lICE -lXpm -lXext -lX11" \
./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

NOTE: you might have to do

perl -pi -e 's/action api_validate.h/action api_validate.h\naction arrayobj.c\naction arrayobj.h/' \
   /opt/fdo/SRC/xserver/xorg/GL/symlink-mesa.sh
perl -pi -e 's/api_validate.c\ \\/api_validate.c\ \\\narrayobj.c \ \\/' \
   /opt/fdo/SRC/xserver/xorg/GL/mesa/main/Makefile.am

if arrayobj.h can't be found

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

To make gdm start automatically when the computer boots, there are two options: Recommended: edit /etc/rc.conf -- add

gdm_enable="YES"

If that does not work, then try editing /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

Xgl/Compiz on BSD

Author

Denis F. Latypoff [funky] -- latypoff at yandex.ru

(with minor contributions from others)
返回页首
阅览会员资料 发送站内信件 浏览发表者的主页 MSN Messenger
IOU
老妖


注册时间: 2005-10-07
文章: 1596
来自: 羊疙瘩头村

文章发表于: Sun 2006-08-20 19:22:16    发表主题: 引用并回复

放个截图上来看~~~~~~~~~~~~~~~~~~~~~~~~~~看!
返回页首
阅览会员资料 发送站内信件
哈蜜瓜
道童


注册时间: 2002-10-29
文章: 241

文章发表于: Sun 2006-08-20 19:33:01    发表主题: 引用并回复

xgl是由novell及suse开发
我是从SuSE 10.1上首先用上这个,
那效果实在是爽呆了,酷逼了!
在FreeBSD上实现xgl确实很麻烦
照着文档弄了一个下午总算出来了。
不过我相信很快会有glx出现在FreeBSD ports中
让我们期待

提供几个链接:
http://www.visionunion.com/article.jsp?code=200603150018
http://www.novell.com/linux/xglrelease/
返回页首
阅览会员资料 发送站内信件 浏览发表者的主页 MSN Messenger
IOU
老妖


注册时间: 2005-10-07
文章: 1596
来自: 羊疙瘩头村

文章发表于: Sun 2006-08-20 20:47:59    发表主题: 引用并回复

够炫,比windows桌面漂亮。GUI玩物。

实用意义不大。桌面切换用不着这么酷吧。我的fvwm有24个桌面,来回切换比这快。

个人感受,喜欢就好。
返回页首
阅览会员资料 发送站内信件
zhangweizj
半仙


注册时间: 2006-05-17
文章: 170

文章发表于: Mon 2006-08-21 18:58:21    发表主题: 引用并回复

厉害。。,但是不知道KDE下怎么实现。
返回页首
阅览会员资料 发送站内信件
diabolo
半仙


注册时间: 2003-12-19
文章: 23

文章发表于: Sun 2006-09-03 18:53:15    发表主题: 内存够大 引用并回复

我看介绍上写着"memory hungry"
返回页首
阅览会员资料 发送站内信件
zhangweizj
半仙


注册时间: 2006-05-17
文章: 170

文章发表于: Sat 2006-10-14 09:07:01    发表主题: 引用并回复

XGL已经停止开发了吧,现在出现新的分支了。。
返回页首
阅览会员资料 发送站内信件
aran
半仙


注册时间: 2007-05-04
文章: 3

文章发表于: Fri 2007-05-04 08:53:13    发表主题: 引用并回复

很好啊~~~
返回页首
阅览会员资料 发送站内信件
wpppl.108
半仙


注册时间: 2007-05-11
文章: 20

文章发表于: Wed 2007-05-16 11:45:13    发表主题: 引用并回复

IOU 写到:
放个截图上来看~~~~~~~~~~~~~~~~~~~~~~~~~~看!
返回页首
阅览会员资料 发送站内信件
bleakwind
老妖


注册时间: 2005-01-07
文章: 1342
来自: The Matrix

文章发表于: Tue 2007-10-30 04:29:57    发表主题: 引用并回复

看我的freebsd...
















_________________
听不到你的声音,只有风声在想...
返回页首
阅览会员资料 发送站内信件 发送电子邮件 浏览发表者的主页 MSN Messenger
cn8h9
半仙


注册时间: 2007-10-24
文章: 43

文章发表于: Fri 2007-11-02 13:48:33    发表主题: 引用并回复

正点,太历害了,
是怎么实现的,老兄,
。。。。。。。。。。。初学者请教一下
返回页首
阅览会员资料 发送站内信件
skyrose
半仙


注册时间: 2007-03-14
文章: 105

文章发表于: Mon 2008-03-24 22:28:30    发表主题: 引用并回复

FreeBSD 7是不是一样安装?
返回页首
阅览会员资料 发送站内信件
从以前的文章开始显示:   
发表新文章   这个论题已经被锁定,您不能发表、回复或者编辑文章。    FreeBSD China -> 安装-配置-优化-安全 论坛时间为 北京时间
1页/共1

 
转跳到:  
不能发布新主题
不能在这个论坛回复主题
不能在这个论坛编辑自己的文章
不能在这个论坛删除自己的文章
不能在这个论坛发表投票


Powered by phpBB 2023cc © 2003 Opensource Steps; © 2003-2009 The FreeBSD Simplified Chinese Project
Powered by phpBB © 2001, 2005 phpBB Group
Protected by Project Honey Pot and phpBB.cc
silvery-trainer
The FreeBSD China Project 网站: 中文计划网站 社区网站
The FreeBSD China Project 版权所有 (C) 1999 - 2003 网页设计版权 著作权和商标