2006年11月5日 星期日

收視率

收視率,目前主導台灣電視台產業的奇怪數字。建議大家讀一下這兩篇文章。

關於收視率
http://www.wretch.cc/blog/deardale&article_id=2185523

我們的社會優劣,取決於小數點後面的數字
http://www.wretch.cc/blog/deardale&article_id=3390613

2006年11月3日 星期五

debpatch 0.99.10

[lang_zh]
這幾天幫 debpatch 加了新功能 :D

debpatch 舊的功能是自動幫 package 加 patch 然後重新 dpkg-buildpackage 出新的 deb。你所需要做的事是把你的 patch 丟到 /etc/debpatch/PACKAGE.d/ 底下。甚至 patch 之前,還可以 prepatch (PACKAGE.prepatch) 他(例如說在 debian/rules 裡面加一行
include /usr/share/cdbs/1/rules/simple-patchsys.mk

但是如果今天要 patch 的 package 是 locales 的一個檔案(我有這個需求,因為要改 UTF-8.gz),就得把「整個」glibc 重編... 所以我這兩天幫 debpatch 加上新功能,來「取代」package 裡的檔案。

所以現在我要做的事情就變成把我的 UTF-8.gz 丟到 /etc/debpatch/locales.d/data/usr/share/i18n/charmaps/UTF-8.gz 然後 build 就行了 :D (注意那個 data 目錄,概念上可以當成是 install 時的根目錄)
[/lang_zh]

[lang_en]
I add a new feature to debpatch :)

debpatch is a application to help you patch package in a easy manner, it'll like to put your patch in to /etc/debpatch/PACKAGE.d/ or prepatch with /etc/debpatch/PACKAGE.prepatch .

But when I wanted to patch a file like /usr/share/i18n/charmaps/UTF-8.gz , I had to rebuild the whole glibc package"s", which are a big job. So I added a new feature to replace files during these few days.

So what I have to do now is to put my own UTF-8.gz into /etc/debpatch/locales.d/data/usr/share/i18n/charmaps/UTF-8.gz and rebuild. That's it. (Note the "data" directory. Conceptually it can be regarded as the root directory when you install that package)
[/lang_en]

2006年11月1日 星期三

ar / dpkg-deb

[lang_zh]
昨天我提過的問題我在一個討論串中找到答案了。

ar 有不同的版本,例如 SVr4/GNU 的 ar 包成 archive 時,檔名是以 '/' 當作結尾,而 BSD 的 ar 不是。dpkg 用的是 BSD 的格式(而不是 GNU? XD),所以當我在 Debian 上用 GNU 的 ar 做 deb 時,檔名是用 '/' 結尾。而 apt-get 抓下來安裝時,卻發現檔名多了 '/',這不是他喜歡的樣子。

新的 dpkg 應該是同時 support 兩種格式的,但是我測試的 package (in fact, it's locales) 裡面的 debian-binary 是 2.0 (舊版)。不過.. dpkg tools 好像還是沒支援對 deb 寫入的功能 :(

暫時先不理他好了,反正這是 harmless ..
[/lang_zh]

[lang_en]
My problem is located in this discussion

There are different versions of ar. SVr4/GNU's ar packs archive with filename delimited by '/', but BSD's doesn't. dpkg(1) uses BSD's ar format (instead of GNU? XD). So what I built my deb with GNU ar, filenames are end with '/'. When apt-get is trying to install it, it found the filename is not what it expects.

New dpkg supposes to support both format, but the package I'm working on (in fact, it's locales) says it's debian-binary is 2.0, which is old. Anyway, it seems that dpkg tools doesn't support writing to deb until now.

Well, I guess I could ignore it since it's harmless..
[/lang_en]