显示标签为“xfce”的博文。显示所有博文
显示标签为“xfce”的博文。显示所有博文

2006年7月15日星期六

搞定xfce-4.4beta2的cygwin移植版本

Cygwin Port of XFCE 4

有4.4beta1在前,这个版本(4.4beta2,即4.3.90.2)搞起来就容易多了,回头整理一下patch,看看有哪些可以提交给upstream.

前 段时间有两个网友问那些free software是不是直接在cygwin下编译一下就可以用了,我说也可以说是,也不是。虽然cygwin对POSIX的模拟和众多cygwin包的贡 献使得移植工作已经相当容易了,还是有些细节(比如fork啊,named pipe啊,文件命名啊,文件权限啊,动态库符号解析啊)方面折腾起来比较麻烦。

其中一位想干脆在mingw下编译一下GNOME桌面然后 跑起来,但目前似乎只有GNOME的一些核心库(即platform部分)已经一直过来了,而bindings似乎只有跟gtk+相关的一部分,至于 desktop部分似乎一直过来也没有意义, admin部分就更不用提了。

2006年4月30日星期日

xfce 4.4beta1 (图?)

XFCE 4.4beta1在几天前出来了,俺编译了一下,感觉还不错。

xfce 4.4beta1

4.4的新特性有:

  • 终于不能免俗,支持桌面图标了。不过支持"最小化到桌面",这点我喜欢
  • 文件管理器换成了新一代的Thunar,感觉还不错,不象xffm那么杂乱。不过我用rox已经习惯了
  • 将Terminal, mousepad正式收录了
  • xfcalendar改名为orage,并且可以计划日程
  • xftaskbar也变成了一个panel
  • iconbox变成了panel的一个插件,systray, showdesktop也收录了进来
BTW: 新的主题(包含gtk2主题和xfwm4主题)我觉得挺好看

2005年11月17日星期四

gdm: 如何禁用不需要的会话(session)名

一不留神,成了公司论坛上的"Linux"版的专家。昨天收到一个问题问如何禁用gdm中的某些会话(session)名称。

记得以前装xfce4时也碰到过类似的问题,只是当时想在上面添加一项xfce4。但当时看遍了/etc/X11/gdm下的文件也没看出怎么设置,只好等到后来debian自己提供了这个条目。

怎么解决呢?

[@more@]
拉下gdm的源代码翻了一下,发现它似乎是这样的: 寻找/usr/share/xsession/下的.desktop文件,如果里面Hidden为false(这也是缺省值)就显示它,否则就不显示。

好在debian提供了包文件搜索,我可以进一步验证哪些包提供了这个目录下的文件: 搜索usr/share/xession即可看出,众多的wm也提供了这个目录下的文件,而gdm提供的文件中只有两个.desktop文件,另外一个明显不是。基本可以确认了。找个闲着的机器试验一下就可以正式确认。

P.S 比较奇怪的是xfce4的这个文件是由xfce4-utils提供的,而不是xfce4-session.

2005年8月31日星期三

porting xffm-4.3 to cygwin


GnomeFiles上看见了xffm-4.3.3的出现,我对xfce4的印象还不错,尤其在Cygwin上没有其他桌面环境(DE)可以用的情况下,于是拉下来编译。

xffm4的名声似乎一直不太好,所以也是后来xfce4开发小组一直说要重点改进的。这个4.3是个测试版本,相对前一版本而言,增加了不少功能,比如新增了iconview和deskview(就是windows那样放在桌面的应用程序启动程序),一个applicatios模块(支持标准的.desktop文件)。

我对xffm的功能齐全还是比较满意,这么点大的程序有书签、查找、垃圾筒、文件比较、fstab、recent各项功能。只是界面却越来越显得混乱,原来只有treeview模式还好一点,但现在4.3又添加了deskview、iconview并且将这二者改为缺省了,进来就觉得有些乱,而一个文件夹从iconview转到detailed view时居然还需要另外打开一个窗口。另外有些地方(比如Goto, Run的输入条)明显是rox的风格,但rox用起来明显简洁多了。

虽然xffm的代码结构经过大幅调整,在Cygwin编译它仍然是一个恶梦,因为xffm对于应用程序、静态库、动态库、插件根本没有一个明确的划分,按原来的编译方式得有大约12个库文件生成到/usr/lib下。我不得不大幅更改Makefile.am, 将libs下的所有库编译到一个libxffm.la的动态库中去,其他的再链接到这个库。附带的一个收获是增加了对automake的了解 :-)。(过两天整理一下放上来)

2005年5月28日星期六

My Cygwin Repository近期更新

我的Cygwin Repository有些日子没有更新了(除了上个月应一些朋友的要求提供了xfce-4.2.1.1),总算更新了一把:

  • sylpheed-claws更新到了1.0.4a(gtk1)和1.9.9(gtk2)
  • 新提供了scite-1.62, 包括gtk1和gtk2版本
  • 新提供了gtk-theme-switch-2.0.3, gtk-chtheme-0.3.1
  • 新提供了bluefish-1.0

  • 上月更新: gqview-2.1.0, gtkpod-0.88.2, leafpad-0.7.9

gtk1的东西还是基于cygnome的, 毕竟cygwin官方包里的gtk缺乏支撑包,而cygnome又比较稳定。(原来在release/目录下提供过一个用cygwin net release的gtk-1.2的包编译的sylpheed-claws,现在已经删除了。)近期如果有空的话,还打算针对cygnome做一次更新,主 要解决python-gnome-1.x的问题。

gtk2的东西倒是都基于cygwin提供的gtk2了。目前还在折腾的是notecase, 而rox, bmp, gwhere等上游也都有新版本等待更新(gaim是不打算维护了,反正它自己也有win32版本,倒是有可能继续搞搞openq的win32版本)。

2005年4月1日星期五

cygwin port of xffm-4.2 almost done

Today:
- Removed the stupid cygwin handling in fstab_module.c. Now you can also visit your DOS drives in the Fstab branch.
- Fixed the window title when goto a network share folder (in cygwin, //machine/service always works even without smb module)
- Now all fixes could be done via automake
- Now xffm seems to be much more stable

Some problems:
- When traversing on the main menu, gtk always complains "assertion `GTK_IS_CHECK_MENU_ITEM (check_menu_item)' failed"
- I can't bookmark a directory in network share folder (dnd.c? or is it also a problem in the upstream?)

About xffm itself:
- The usability is much better than 4.0
- Some UI parts are not instinctive. For example, the sidebars, I lost it by accident. But if I didn't check the manual, I couldn't know how to get it back.



Source patches are here(xffm-4.2.1-cygwin-patch.tar.gz).

Usage:
xffm-4.2.1-cygwin-automake.patch is for those who have automake installed.
$ tar zxf xffm-4.2.1.tar.gz # unpack source
$ cd xffm-4.2.1
$ patch -p1 -b <>
$ CFLAGS=-O2 ./configure --prefix=/opt/xfce4
$ /usr/autotool/devel/bin/automake-1.9
$ make
$ make install

xffm-4.2.1-cygwin.patch is for those who don't have automake.
$ tar zxf xffm-4.2.1.tar.gz # unpack source
$ cd xffm-4.2.1
$ patch -p1 -b <>
$ CFLAGS=-O2 ./configure --prefix=/opt/xfce4
$ make
$ make install

The -automake patch is smaller, which makes the patch maintainable.

Note:
If you want to build in a directory other than the source directory (e.g. xffm-4.2.1/.build, ) via "./configure --srcdir=/path/to/source/dir", remember to copy the faked src/libxffm.la to $(top_builddir)/src/.

2005年3月15日星期二

xffm back to cygwin!

从cygwin/windows的角度来看,xffm(这里指4.2版本)的代码模块化方面可谓混乱之极, xffm可执行文件和一堆共享库相互依赖,这在Windows下是不允许的。这就使得xffm-4.2非常难以移植到cygwin上来。

但今天终于再此搞定了,虽然费了整整一天。(但我还是更喜欢用rox)
大致的方法如下:

- 将smb模块和将libs目录下的库编译为静态库

- 将xffm与上述模块进行链接,得到xffm.exe, 用dlltool 输出(export)xffm.exe的全部public符号

- modules下的模块全部依赖于xffm.exe

xffm-4.2 in cygwin

From the viewpoint of cygwin/windows, the module structure of xffm-4.2 is a whole mass. The xffm executable and a pack of shared libraries used each other's symbols, which is not allowed on
cygwin/windows. This made it very hard to port xffm-4.2 to cygwin.

But now xffm (4.2) is back to cygwin! I spent a whole day on this. (Nevertheless I'd prefer rox to xffm).

- Turn the libraries in directory `libs' into static libraries
- Link xffm against the libraries above and then we have xffm.exe. Use dlltool to export all the public symbols of xffm.exe.
- Link the modules in directory `modules' against xffm.exe.




依赖于libs目录下的一堆库,这些库当中又有引用xffm中的符号的情况;smb模块似乎是可以不编译的,但
libs目录下面的那些库偏偏又用到了smb可加载情况下才有的一些功能;另外modules目录学唉还有一堆插件,实现书签、回收站等虚拟文件系统;
xfdiff4这个小功能也需要libs目录下的libxffm_secondary里面的一些函数。

因为windows下不允许一个可执行文件或者动态库中包含未定义的符号, 所以需要仔细界定一个函数或者变量是在哪里实现,所以从4.1.90版本开始一直搞不定这个东西的移植,每次开始折腾一会儿就晕了。

仔细琢磨了一下代码结构,发掘其实也蛮简单,将原来libs下面的共享库变成静态库不就行了?

但这样的大调整,仅仅靠修改Makefile.in不禁会繁死,而且还很难成功,因为有些东西(比如将编译动态库改为编译静态库,因为用了libtool这些东西)靠修改Makefile.in不知道怎么下手。
于是我从Makefile.am下手,运气好的是,用automake重新生成Makefile.in很顺利,并没有用到什么目前cygwin下面没有的宏。

源代码补丁正在整理中,过两天就可以上载到主页上去了。

The xffm executable used some symbols defined in the libraries in
directory `libs', but these libs also reference some symbols defined
in the xffm executable; the smb module seems to be loadable, for
supporting some systems that don't have smb support , but the libraries
in `libs' insist to call some functions implmented in smb module.



As Windows doesn't allow undefined symbols in the executable and shared
libraries, thus we should know exactly where a symbols is implemented.
Starting from version 4.1.90 of xffm, I neven succeed in porting xffm
to cygwin. Every time I started to work on it, I would be confused and
disoriented just in a few minutes.

I
walked through the code structure, suddenly the God shed some lights on
me: why not just build those libraries into static ones and link xffm
to them?
Then I tried, works! (This change requires me to hacked the Makefile.ams. I'm not familar with
automake/autoconf. But fortunately enough, I got no any error when
running automake.)

Now I'm examining the modification to got a source patch. Maybe you can see it on my repository in a few days.

2005年3月1日星期二

source patches for xfce4-4.2.1.1 cygwin port

I've uploaded the source patches to my cygwin repository. (directly download, detail info)

- Patch for Terminal-0.2.4 (and dbus, exo)
also included (note: vte required).
- I improved the autobuild script a lot. Each package could be configurable in autobuild.conf.

Still no binary packages, due to bandwidth
limit. I'm tring to find a wide band to upload them in this week.

2004年11月19日星期五

Cygwin: 搞定XFCE 4.2rc1

前两日搞定将xfce 4.2rc1(4.1.99.1)移植到cygwin的补丁,在原来4.2beta1(4.1.90)上做的,并没有改多少,但一些补丁修了一下。

因为搬家后在家里没有电脑用了,也就没有办法提供编译好的版本了,目前只有补丁,可从我的主页下载
xfce4-4.2rc1-cygwin-patches.zip

xffm还是没有做(在4.2beta1就没有做,因为它似乎越来越难移植了,可执行文件与共享库、插件之间代码分工混乱之极,我还是用我的rox吧,反正还有mc或者windows自己的文件管理工具).

xfce4-print和xfce4-mixer不能完全工作──虽然两者都可以编译通过。