GNOME パッケージガイドライン
32ビット – CLR – クロス – Eclipse – Electron – Free Pascal – GNOME – Go – Haskell – Java – KDE – カーネル – Lisp – MinGW – Node.js – ノンフリー – OCaml – Perl – PHP – Python – R – Ruby – Rust – VCS – ウェブ – Wine
Arch Linux では GNOME パッケージは特定の決まり事に従っています。
目次
GNOME プロファイルの初期化
GNOME プロファイルの初期化は必要なくなりました。以下のような行が PKGBUILD にある場合は取り除いて下さい:
[ -z "$GNOMEDIR" ] && . /etc/profile.d/gnome.sh
GConf スキーマ
多くの GNOME パッケージは GConf スキーマをインストールします。スキーマはシステムの GConf データベースにインストールされますが、それは避けねばなりません。パッケージによっては ./configure で --disable-schemas-install スイッチを使っていますが、これが上手く機能することは稀です。その代わりに、gconftool-2 には GCONF_DISABLE_MAKEFILE_SCHEMA_INSTALL という変数が存在し、この変数が設定された場合、gconftool-2 はデータベースをアップデートしません。
スキーマファイルをインストールするパッケージを作成するときは、PKGBUILD のパッケージのインストールの段階で以下を使ってください:
make GCONF_DISABLE_MAKEFILE_SCHEMA_INSTALL=1 DESTDIR=${pkgdir} install
GConf スキーマは .install ファイルで pre_remove, pre_upgrade, post_upgrade, post_install を使ってインストール・削除する必要があります。gconf-merge-schemas を使用して複数のスキーマは一つのファイルにまとめて、usr/sbin/gconfpkg --(un)install $pkgname でインストール・アンインストールしてください。gconfpkg を使用するには gconf>=2.18.0.1-4 (もしくは gconfmm>=2.20.0) を依存パッケージにする必要があります。
GSettings スキーマ
The GConf schemas will be replaced by GSettings schemas in the near future, but some applications (e.g. Empathy) already using it. GSettings uses dconf as backend, so all packages that contain GSettings schemas require dconf as dependency. When a new GSettings schema installed on the system, the GSettings database should be recompiled, but not when packaging.
To avoid recompiling GSettings database on packaging, use the --disable-schemas-compile switch for ./configure. To recompile it on install, add the following line to the .install file using post_install, post_upgrade and post_remove:
glib-compile-schemas usr/share/glib-2.0/schemas
Scrollkeeper ドキュメント
GNOME 2.20 から scrollkeeper を利用する必要はなくなりました。rarian が直接 OMF ファイルを読み込みます。現在 Scrollkeeper-update はダミーになっています。makedepend に gnome-doc-utils>=0.11.2 を追加すること以外は何もしなくてかまいません。
.desktop ファイル
Many packages install Freedesktop.org compatible .desktop files and register MimeType entries in them. Running update-desktop-database -q in post_install and post_remove is recommended (package should depend on desktop-file-utils in this case).
GTK アイコンキャッシュ
パッケージが hicolor アイコンテーマにアイコンをインストールする場合があります。パッケージを gtk-update-icon-cache に依存するようにして post_install, post_upgrade, post_remove 関数で gtk-update-icon-cache -q -t -f usr/share/icons/hicolor を実行してください。
.install ファイル
For many GNOME packages, all .install files look almost exactly the same. The gedit package contains a very generic install file: https://projects.archlinux.org/svntogit/packages.git/tree/gedit/repos/extra-x86_64/gedit.install
Basically, the only thing that has to be changed is the pkgname variable on top of the .install file. As long as pacman does not supply us with the pkgname variable, we need to supply it in the .install file.
When packages do not have gconf schemas, hicolor icon files, or .desktop files, remove the parts that handle those subjects.
サンプル
For an example of above rules, take a look at the gedit PKGBUILD and the .install file supplied above:
https://projects.archlinux.org/svntogit/packages.git/tree/gedit/repos/extra-x86_64/