Difference between revisions of "JA/Documentation/Building Guide/Building on Linux"

From Apache OpenOffice Wiki
Jump to: navigation, search
(--with-use-shell=bash removed)
 
(5 intermediate revisions by the same user not shown)
Line 12: Line 12:
  
 
= Overview / 概要 =
 
= Overview / 概要 =
{{Template:Documentation/Linux|This document describes building OpenOffice.org on Linux.<br>このドキュメントは Linux で OpenOffice.org のビルドを行う方法について説明します。(訳注:原文の最新版ではこのタグは削除されています)}}
+
{{Lin|This document describes building OpenOffice.org on Linux.<br>このドキュメントは Linux で OpenOffice.org のビルドを行う方法について説明します。(訳注:原文の最新版ではこのタグは削除されています)}}
{{Template:Documentation/Note|<code>$SRC_ROOT</code> will denote the directory in which the source code of OpenOffice.org is stored.<br><code>$SRC_ROOT</code> は、 OpenOffice.org のソースコードを保存したフォルダのことを指しています。}}
+
{{Template:Note|<code>$SRC_ROOT</code> will denote the directory in which the source code of OpenOffice.org is stored.<br><code>$SRC_ROOT</code> は、 OpenOffice.org のソースコードを保存したフォルダのことを指しています。}}
{{Template:Documentation/Tip|You are advised to check the release notes for the release you are building to inform yourself about changes since previous releases.<br>ビルドするリリースが、前回のリリースからどのように変更されているかは、リリースノートを参照してください。}}
+
{{Tip|You are advised to check the release notes for the release you are building to inform yourself about changes since previous releases.<br>ビルドするリリースが、前回のリリースからどのように変更されているかは、リリースノートを参照してください。}}
  
 
= Requirements / システム要件 =
 
= Requirements / システム要件 =
Line 30: Line 30:
 
== software requirements / ソフトウェア ==
 
== software requirements / ソフトウェア ==
  
{{Template:Documentation/Tip|You can find distribution specific package lists in the [http://wiki.services.openoffice.org/wiki/Category:Distribution-Specific_Build_Instructions Distribution specific build instructions pages].<br>[http://wiki.services.openoffice.org/wiki/Category:Distribution-Specific_Build_Instructions Distribution specific build instructions pages]で、使用しているディストリビューションの特定パッケージリストを見ることができます。}}
+
{{Tip|You can find distribution specific package lists in the [http://wiki.services.openoffice.org/wiki/Category:Distribution-Specific_Build_Instructions Distribution specific build instructions pages].<br>[http://wiki.services.openoffice.org/wiki/Category:Distribution-Specific_Build_Instructions Distribution specific build instructions pages]で、使用しているディストリビューションの特定パッケージリストを見ることができます。}}
  
 
* glibc:
 
* glibc:
Line 45: Line 45:
 
** gcc 4.2.3 が最新版です(訳注:4.4.2が最新です)
 
** gcc 4.2.3 が最新版です(訳注:4.4.2が最新です)
  
* The X11 development libraries and header files<ref name="Foot1e">{{Template:Documentation/Note|Should be in place with most Linux distributions. Note the there are currently some issues with X version 4.3.}}</ref>
+
* The X11 development libraries and header files<ref name="Foot1e">{{Note|Should be in place with most Linux distributions. Note the there are currently some issues with X version 4.3.}}</ref>
* X11のヘッダーファイルと開発用ライブラリ<ref name="Foot1">{{Template:Documentation/Note|ほとんどの Linux ディストリビューションで適切な場所にあるべきです。注意:現在、 X のバージョン 4.3 にはいくつか問題があります。}}</ref>
+
* X11のヘッダーファイルと開発用ライブラリ<ref name="Foot1">{{Note|ほとんどの Linux ディストリビューションで適切な場所にあるべきです。注意:現在、 X のバージョン 4.3 にはいくつか問題があります。}}</ref>
  
* PAM including the development headers<ref name="Foot2e">{{Template:Documentation/Note|PAM should be installed by default on most linux distributions. You should only need to add the development package.}}</ref>
+
* PAM including the development headers<ref name="Foot2e">{{Note|PAM should be installed by default on most linux distributions. You should only need to add the development package.}}</ref>
* 開発用ヘッダーを含む PAM<ref name="Foot2">{{Template:Documentation/Note|PAM は、ほとんどの Linux ディストリビューションに標準でインストールされています。あとは、開発用パッケージを追加するだけです。}}</ref>
+
* 開発用ヘッダーを含む PAM<ref name="Foot2">{{Note|PAM は、ほとんどの Linux ディストリビューションに標準でインストールされています。あとは、開発用パッケージを追加するだけです。}}</ref>
  
 
* bash
 
* bash
 
* bash
 
* bash
  
* gtk2 and libtiff including the development headers<ref name="Foot4e">{{Template:Documentation/Note|The gtk2, jpeg and tiff libraries are not required if you disable the crash-reporter when running <CODE>./configure</CODE>.}}</ref>
+
* gtk2 and libtiff including the development headers<ref name="Foot4e">{{Note|The gtk2, jpeg and tiff libraries are not required if you disable the crash-reporter when running <CODE>./configure</CODE>.}}</ref>
* 開発用ヘッダーを含む gtk2 と libriff<ref name="Foot4">{{Template:Documentation/Note|<CODE>./configure</CODE> を実行するときに、クラッシュレポーターを無効にするのなら、 gtk2 や jpeg および tiff ライブラリは必要ではありません。}}</ref>
+
* 開発用ヘッダーを含む gtk2 と libriff<ref name="Foot4">{{Note|<CODE>./configure</CODE> を実行するときに、クラッシュレポーターを無効にするのなら、 gtk2 や jpeg および tiff ライブラリは必要ではありません。}}</ref>
  
 
(訳注:[[Ubuntu_Build_Instructions]]にUbuntu 9.10用のパッケージインストールのスクリプトがあります。また、訳者の環境では、さらに libcurl3-gnutls-dev のインストールが必要でした。)
 
(訳注:[[Ubuntu_Build_Instructions]]にUbuntu 9.10用のパッケージインストールのスクリプトがあります。また、訳者の環境では、さらに libcurl3-gnutls-dev のインストールが必要でした。)
Line 87: Line 87:
 
お使いのプラットフォームの詳細については、 configure スクリプトの末尾の情報欄か [[:Category:Distribution-Specific_Build_Instructions]](英語) を見てください。
 
お使いのプラットフォームの詳細については、 configure スクリプトの末尾の情報欄か [[:Category:Distribution-Specific_Build_Instructions]](英語) を見てください。
  
{{Documentation/Caution| Please check for any warnings emitted by the configure-script.<br>configure スクリプトが出す、すべての warnings(警告) をチェックしてください。}}
+
{{Warn| Please check for any warnings emitted by the configure-script.<br>configure スクリプトが出す、すべての warnings(警告) をチェックしてください。}}
  
 
== bootstrap / ブートストラップ ==
 
== bootstrap / ブートストラップ ==
Line 100: Line 100:
 
== setting the environment / 環境の設定 ==
 
== setting the environment / 環境の設定 ==
  
When the configure script has been run successfully a file <code>LinuxX86Env.Set.sh</code> or <code>LinuxX86-64Env.Set.sh</code> was created<ref name="Foot5e">{{Template:Documentation/Note|When you want to use tcsh instead of bash, you will need to use the file <code>LinuxX86Env.Set</code> instead:<br>
+
When the configure script has been run successfully a file <code>LinuxX86Env.Set.sh</code> or <code>LinuxX86-64Env.Set.sh</code> was created<ref name="Foot5e">{{Note|When you want to use tcsh instead of bash, you will need to use the file <code>LinuxX86Env.Set</code> instead:<br>
 
<pre> source LinuxX86Env.Set
 
<pre> source LinuxX86Env.Set
 
  rehash</pre>
 
  rehash</pre>
Line 106: Line 106:
 
</ref>.
 
</ref>.
 
Do this:<br>
 
Do this:<br>
configure スクリプトが正常に実行されると、 <code>LinuxX86Env.Set.sh</code> または <code>LinuxX86-64Env.Set.sh</code> が作成されます。<ref name="Foot5">{{Template:Documentation/Note|bash の代わりに tcsh を使用している場合は、代わりに <code>LinuxX86Env.Set</code> を使用します。<br>
+
configure スクリプトが正常に実行されると、 <code>LinuxX86Env.Set.sh</code> または <code>LinuxX86-64Env.Set.sh</code> が作成されます。<ref name="Foot5">{{Note|bash の代わりに tcsh を使用している場合は、代わりに <code>LinuxX86Env.Set</code> を使用します。<br>
 
<pre> source LinuxX86Env.Set
 
<pre> source LinuxX86Env.Set
 
  rehash</pre>
 
  rehash</pre>
Line 119: Line 119:
  
 
to set up the environment for the build<ref name="Foot6e">By default, native packages (.deb/.rpm) will be build.<br>
 
to set up the environment for the build<ref name="Foot6e">By default, native packages (.deb/.rpm) will be build.<br>
{{Template:Documentation/Tip|If you want to have something faster and easier to test:<br>
+
{{Tip|If you want to have something faster and easier to test:<br>
 
<pre>export FORCE2ARCHIVE=true</pre>
 
<pre>export FORCE2ARCHIVE=true</pre>
 
This will create a tarball that can easily be unpacked and run anywhere.}}
 
This will create a tarball that can easily be unpacked and run anywhere.}}
 
</ref>.<br>
 
</ref>.<br>
 
ビルドのための環境をセットします。<ref name="Foot6">デフォルトでは、ネイティブパッケージ(.deb/.rpm) をビルドします。<br>
 
ビルドのための環境をセットします。<ref name="Foot6">デフォルトでは、ネイティブパッケージ(.deb/.rpm) をビルドします。<br>
{{Template:Documentation/Tip|もし、高速で簡単にテストをしたい場合は、<br>
+
{{Tip|もし、高速で簡単にテストをしたい場合は、<br>
 
<pre>export FORCE2ARCHIVE=true</pre>
 
<pre>export FORCE2ARCHIVE=true</pre>
 
これは、どこでも簡単に解凍・実行できるターボール(tarball) を作成します。}}
 
これは、どこでも簡単に解凍・実行できるターボール(tarball) を作成します。}}
Line 130: Line 130:
  
 
== starting the build / ビルドの開始 ==
 
== starting the build / ビルドの開始 ==
Build the software by typing the following in <code>$SRC_ROOT</code><ref name="Foot7e">{{Template:Documentation/Note|You can also run:<br>
+
Build the software by typing the following in <code>$SRC_ROOT</code><ref name="Foot7e">{{Note|You can also run:<br>
 
<pre>make</pre>
 
<pre>make</pre>
 
but GNU make will just start build.pl.
 
but GNU make will just start build.pl.
Line 136: Line 136:
 
<pre>build --help</pre>}}
 
<pre>build --help</pre>}}
 
</ref>:<br>
 
</ref>:<br>
<code>$SRC_ROOT</code> で以下を打ち込んでビルドを開始します。<ref name="Foot7">{{Template:Documentation/Note|代わりに以下を実行できます。<br>
+
<code>$SRC_ROOT</code> で以下を打ち込んでビルドを開始します。<ref name="Foot7">{{Note|代わりに以下を実行できます。<br>
 
<pre>make</pre>
 
<pre>make</pre>
 
しかし、 GNU make は build.pl を開始するだけです。
 
しかし、 GNU make は build.pl を開始するだけです。
Line 155: Line 155:
 
Only do compatible partial builds if you know exactly what you are doing.<br>
 
Only do compatible partial builds if you know exactly what you are doing.<br>
 
何を行っているのか正確に分かっている場合は、 compatible部分ビルドを行ってください。
 
何を行っているのか正確に分かっている場合は、 compatible部分ビルドを行ってください。
{{Documentation/Note|For more information, see [[Compatible Builds]].<br>より詳しい情報は、 [[Compatible Builds]](英語) を見てください。}}
+
{{Note|For more information, see [[Compatible Builds]].<br>より詳しい情報は、 [[Compatible Builds]](英語) を見てください。}}
  
 
== rebuilding from a module (incompatible build) / モジュールの再ビルド(incompatible ビルド) ==
 
== rebuilding from a module (incompatible build) / モジュールの再ビルド(incompatible ビルド) ==
Line 175: Line 175:
 
  build && deliver
 
  build && deliver
  
A simple <code>build</code> in <code>$SRC_ROOT/instsetoo_native</code> will recreate the installation sets, provided all other modules have already been build.<ref name="Foot8e">{{Documentation/Caution|<code>build --all</code> would rebuild changed/missing files. However, it does not check for incompatible modules. If unsure, use <code>build --from --prepare</code>.}}
+
A simple <code>build</code> in <code>$SRC_ROOT/instsetoo_native</code> will recreate the installation sets, provided all other modules have already been build.<ref name="Foot8e">{{Warn|<code>build --all</code> would rebuild changed/missing files. However, it does not check for incompatible modules. If unsure, use <code>build --from --prepare</code>.}}
 
</ref><br>
 
</ref><br>
他のモジュールがすでにビルドされているなら、<code>build</code> は、簡単にインストールセットを <code>$SRC_ROOT/instsetoo_native</code> に再作成します。<ref name="Foot8">{{Documentation/Caution|<code>build --all</code> は、変更された、もしくは見つからないファイルを再ビルドします。しかし、非互換性のモジュールをチェックしません。不確かなら <code>build --from --prepare</code> を使用します。}}
+
他のモジュールがすでにビルドされているなら、<code>build</code> は、簡単にインストールセットを <code>$SRC_ROOT/instsetoo_native</code> に再作成します。<ref name="Foot8">{{Warn|<code>build --all</code> は、変更された、もしくは見つからないファイルを再ビルドします。しかし、非互換性のモジュールをチェックしません。不確かなら <code>build --from --prepare</code> を使用します。}}
 
</ref>
 
</ref>
  
  
{{Documentation/Caution|This does '''not''' check for incompatible modules. If unsure, use an incompatible build (see above).<br>これは、非互換のモジュールについて'''チェックしません'''。不確かなら incompatible ビルド(上記を参照) を行ってください。}}
+
{{Warn|This does '''not''' check for incompatible modules. If unsure, use an incompatible build (see above).<br>これは、非互換のモジュールについて'''チェックしません'''。不確かなら incompatible ビルド(上記を参照) を行ってください。}}
  
  
Line 196: Line 196:
 
新しく作成したバイナリをあらかじめインストールした物に上書きしてください。デフォルトでは、パッケージにするときにインストールセットは省かれます。
 
新しく作成したバイナリをあらかじめインストールした物に上書きしてください。デフォルトでは、パッケージにするときにインストールセットは省かれます。
  
{{Template:Documentation/Tip|For details, see [[Debugging]].<br>詳しくは、[[Debugging]](英語)を見てください。}}
+
{{Tip|For details, see [[Debugging]].<br>詳しくは、[[Debugging]](英語)を見てください。}}
  
 
= Finding Installation Sets / インストールセットの場所 =
 
= Finding Installation Sets / インストールセットの場所 =
Line 202: Line 202:
 
The english installation set will be located at <code>$SRC_ROOT/instsetoo_native/unxlngi6.pro/OpenOffice/{deb,rpm,archive}/install/en-US/</code><ref name="Foot9e">The en-US in the path names indicates that the localization is American English. This value corresponds to the language tags defined by RFC 1766 (Tags for the Identification of Languages). The German installation set will be located in a <tt>de</tt> subdirectory. This scheme holds true for all localizations you may have chosen explicitly.
 
The english installation set will be located at <code>$SRC_ROOT/instsetoo_native/unxlngi6.pro/OpenOffice/{deb,rpm,archive}/install/en-US/</code><ref name="Foot9e">The en-US in the path names indicates that the localization is American English. This value corresponds to the language tags defined by RFC 1766 (Tags for the Identification of Languages). The German installation set will be located in a <tt>de</tt> subdirectory. This scheme holds true for all localizations you may have chosen explicitly.
  
{{Template:Documentation/Tip|Running the configure script with the --with-lang option will introduce the build of additional language resources. This switch accepts one or more RFC 1766 language tags as arguments. Check the value of the <code>completelangiso</code> macro in <code>$SRC_ROOT/solenv/inc/postset.mk</code> for all the currently supported language tags.<br>
+
{{Tip|Running the configure script with the --with-lang option will introduce the build of additional language resources. This switch accepts one or more RFC 1766 language tags as arguments. Check the value of the <code>completelangiso</code> macro in <code>$SRC_ROOT/solenv/inc/postset.mk</code> for all the currently supported language tags.<br>
 
Example:<br>
 
Example:<br>
 
<pre>./configure --with-lang="de fr"</pre>
 
<pre>./configure --with-lang="de fr"</pre>
Line 208: Line 208:
 
languages.}}
 
languages.}}
  
{{Template:Documentation/Note|If you build additional localized languages it is possible to generate Language Packs that contain only the changes needed to add the additional language to an OpenOffice.org of a different language. The following commands will generate language packs languages that were specified with the --with-lang switch during the configure phase. <br>
+
{{Note|If you build additional localized languages it is possible to generate Language Packs that contain only the changes needed to add the additional language to an OpenOffice.org of a different language. The following commands will generate language packs languages that were specified with the --with-lang switch during the configure phase. <br>
 
<pre>cd $SRC_ROOT/instsetoo_native/util
 
<pre>cd $SRC_ROOT/instsetoo_native/util
 
dmake ooolanguagepack</pre>}}
 
dmake ooolanguagepack</pre>}}
{{Template:Documentation/Caution|Note that you can only build the language packs '''after''' you have build the complete office with all selected languages.}}
+
{{Warn|Note that you can only build the language packs '''after''' you have build the complete office with all selected languages.}}
 
</ref>.<br>
 
</ref>.<br>
 
英語版のインストールセットは次の場所にできます。<code>$SRC_ROOT/instsetoo_native/unxlngi6.pro/OpenOffice/{deb,rpm,archive}/install/en-US/</code><ref name="Foot9">パスの en-US は、言語が米語であることを示します。この値は RFC 1766(言語識別のためのタグ) で定義された言語タグと対応します。 ドイツ語のインストールセットは、 <tt>de</tt> サブディレクトに作成されます。 これは、明示的に選択された全ての言語版に当てはまります。
 
英語版のインストールセットは次の場所にできます。<code>$SRC_ROOT/instsetoo_native/unxlngi6.pro/OpenOffice/{deb,rpm,archive}/install/en-US/</code><ref name="Foot9">パスの en-US は、言語が米語であることを示します。この値は RFC 1766(言語識別のためのタグ) で定義された言語タグと対応します。 ドイツ語のインストールセットは、 <tt>de</tt> サブディレクトに作成されます。 これは、明示的に選択された全ての言語版に当てはまります。
  
{{Template:Documentation/Tip|configure スクリプトに --with-lang オプションを付けて実行すると追加の言語版もビルドします。このスイッチは一つまたは複数の RFC 1766 言語タグを引数にとります。 現在サポートされている全ての言語タグを見るには、 <code>$SRC_ROOT/solenv/inc/postset.mk</code> にある <code>completelangiso</code> マクロの値をチェックしてください。<br>
+
{{Tip|configure スクリプトに --with-lang オプションを付けて実行すると追加の言語版もビルドします。このスイッチは一つまたは複数の RFC 1766 言語タグを引数にとります。 現在サポートされている全ての言語タグを見るには、 <code>$SRC_ROOT/solenv/inc/postset.mk</code> にある <code>completelangiso</code> マクロの値をチェックしてください。<br>
 
例:<br>
 
例:<br>
 
<pre>./configure --with-lang="de fr"</pre>
 
<pre>./configure --with-lang="de fr"</pre>
 
ドイツ語版とフランス語版のビルドを有効にします。環境変数 <code>WITH_LANG</code> は、追加の言語版の言語タグを含むでしょう(en-US は常にビルドされます)。}}
 
ドイツ語版とフランス語版のビルドを有効にします。環境変数 <code>WITH_LANG</code> は、追加の言語版の言語タグを含むでしょう(en-US は常にビルドされます)。}}
  
{{Template:Documentation/Note|ある言語版の OpenOffice.org に他の異なる言語を加えたい場合、必要な部分だけを含むランゲージパックをビルドすることは可能です。以下のコマンドで 構成時に --with-lang スイッチで指定した言語のランゲージパックを作成します。<br>
+
{{Note|ある言語版の OpenOffice.org に他の異なる言語を加えたい場合、必要な部分だけを含むランゲージパックをビルドすることは可能です。以下のコマンドで 構成時に --with-lang スイッチで指定した言語のランゲージパックを作成します。<br>
 
<pre>cd $SRC_ROOT/instsetoo_native/util
 
<pre>cd $SRC_ROOT/instsetoo_native/util
 
dmake ooolanguagepack</pre>}}
 
dmake ooolanguagepack</pre>}}
{{Template:Documentation/Caution|選択した言語版のofficeを完全ビルドした'''後'''にのみ、ランゲージパックをビルドできることに注意してください。}}
+
{{Warn|選択した言語版のofficeを完全ビルドした'''後'''にのみ、ランゲージパックをビルドできることに注意してください。}}
 
</ref>.
 
</ref>.
  
{{Template:Documentation/Note| For 64-bit Linux it is <code>unxlngx6.pro</code> instead of <code>unxlngi6.pro</code>.<br>
+
{{Note| For 64-bit Linux it is <code>unxlngx6.pro</code> instead of <code>unxlngi6.pro</code>.<br>
 
64bit Linux の場合は、 <code>unxlngi6.pro</code> ではなく、 <code>unxlngx6.pro</code> です。}}
 
64bit Linux の場合は、 <code>unxlngi6.pro</code> ではなく、 <code>unxlngx6.pro</code> です。}}
  
Line 244: Line 244:
 
環境変数の<code>nodep</code>に<code>TRUE</code>を設定した場合は、依存関係情報のファイルを作成しないため、ビルドがより早く終わります。
 
環境変数の<code>nodep</code>に<code>TRUE</code>を設定した場合は、依存関係情報のファイルを作成しないため、ビルドがより早く終わります。
  
{{Template:Documentation/Caution|But only enable that on a clean build. Once you have built OOo and then made modifications, unset the variable again to be on the safe side.<br>クリーンビルド時のみ、有効にしてください。一度、OOoをビルド作成した後で、それに変更を加える場合には、安全にビルドするために、この環境変数をセットしないで(unsetして)ください。}}
+
{{Warn|But only enable that on a clean build. Once you have built OOo and then made modifications, unset the variable again to be on the safe side.<br>クリーンビルド時のみ、有効にしてください。一度、OOoをビルド作成した後で、それに変更を加える場合には、安全にビルドするために、この環境変数をセットしないで(unsetして)ください。}}
  
 
'''NO_HIDS'''
 
'''NO_HIDS'''
Line 303: Line 303:
 
You can easily create your own version of the prepacked binaries if you wish to do so (either because you cannot use the official ones because of mismatch of compiler version used to build them/other technical reasons or because you want to use stuff you didn't build yourself).
 
You can easily create your own version of the prepacked binaries if you wish to do so (either because you cannot use the official ones because of mismatch of compiler version used to build them/other technical reasons or because you want to use stuff you didn't build yourself).
 
To do so:<br>
 
To do so:<br>
mozillaコンポーネントをmozillaのソースからビルドした物か、あらかじめコンパイルされたパッケージを使うか、またはシステムのmoziila<ref name="Foot10">{{Template:Documentation/Note|ビルドを行うシステムにインストールされているもので、インストールしたときのバージョンに依存するため上手く動作しないかもしれないもの}}</ref>から選択します。
+
mozillaコンポーネントをmozillaのソースからビルドした物か、あらかじめコンパイルされたパッケージを使うか、またはシステムのmoziila<ref name="Foot10">{{Note|ビルドを行うシステムにインストールされているもので、インストールしたときのバージョンに依存するため上手く動作しないかもしれないもの}}</ref>から選択します。
 
ビルドに使用するコンパイラのバージョンが異なるため公式パッケージを使用できない場合や、その他の技術的な理由、または、それを使いたいので自分でビルドしなかった場合でも、独自のバージョンのビルド済みパッケージを簡単に作成できます。これを行うには、以下の作業を行います。<br>
 
ビルドに使用するコンパイラのバージョンが異なるため公式パッケージを使用できない場合や、その他の技術的な理由、または、それを使いたいので自分でビルドしなかった場合でも、独自のバージョンのビルド済みパッケージを簡単に作成できます。これを行うには、以下の作業を行います。<br>
  

Latest revision as of 08:51, 16 July 2018

Book.png
[[{{{PrevPage}}}|< 前のページ]] [[{{{NextPage}}}|次のページ >]]

このページは翻訳作業中です(User:Matayoshi)。
翻訳ステータス:翻訳 −> 原文の変更反映 −> 査読 −> 完成
使用した原文の更新日時:2010年2月23日(火) 02:20

Overview / 概要

Documentation linux.png This document describes building OpenOffice.org on Linux.
このドキュメントは Linux で OpenOffice.org のビルドを行う方法について説明します。(訳注:原文の最新版ではこのタグは削除されています)
Documentation note.png $SRC_ROOT will denote the directory in which the source code of OpenOffice.org is stored.
$SRC_ROOT は、 OpenOffice.org のソースコードを保存したフォルダのことを指しています。
Tip.png You are advised to check the release notes for the release you are building to inform yourself about changes since previous releases.
ビルドするリリースが、前回のリリースからどのように変更されているかは、リリースノートを参照してください。


Requirements / システム要件

hardware requirements / ハードウェア

  • 1 or more reasonable fast CPUs, x-way CPU's recommended.
  • 1つ以上の高速な CPU(複数の CPU を推奨します)
  • 1 GB Ram ( 2 GB recommended )
  • 1GByte のメモリー(2GByte を推奨)
  • at least 10 GB free disk space
  • 10GByte 以上のハードディスク空き容量

software requirements / ソフトウェア

Tip.png You can find distribution specific package lists in the Distribution specific build instructions pages.
Distribution specific build instructions pagesで、使用しているディストリビューションの特定パッケージリストを見ることができます。


  • glibc:
    • for OOo<=3.1: 2.2.x or higher
    • OOo3.1以前 : 2.2.x もしくは、それ以降
    • for OOo>3.1: 2.3.2 or higher
    • OOo3.1より後 : 2.3.2 もしくは、それ以降
  • C/C++ Compiler:
  • C/C++ コンパイラー:
    • gcc >= 3.3
    • gcc 3.3 以降
    • gcc 4.2.3 is the current reference compiler
    • gcc 4.2.3 が最新版です(訳注:4.4.2が最新です)
  • The X11 development libraries and header files[1]
  • X11のヘッダーファイルと開発用ライブラリ[2]
  • PAM including the development headers[3]
  • 開発用ヘッダーを含む PAM[4]
  • bash
  • bash
  • gtk2 and libtiff including the development headers[5]
  • 開発用ヘッダーを含む gtk2 と libriff[6]

(訳注:Ubuntu_Build_InstructionsにUbuntu 9.10用のパッケージインストールのスクリプトがあります。また、訳者の環境では、さらに libcurl3-gnutls-dev のインストールが必要でした。)

Full Builds / 完全ビルド

To perform a full build, you need to follow these steps:
完全なビルドを行うには、以下のステップを行う必要があります。

configure / 構成

  • Run the configure script to check all requirements. Run the following command to view all possible options.
  • configure スクリプトを実行してすべての要件をチェックしてください。すべてのオプションを見るには、以下のコマンドを実行します。
./configure --help

An example configure command (on Ubuntu 9.10 with as much libraries by the system used as possible):
構成コマンドの例(Ubuntu 9.10 ではシステムで使用している多くのライブラリを利用することが可能です):

./configure --with-system-libs \
--without-system-jars --without-system-icu --without-system-agg \
--without-system-lpsolve --without-system-mspack --disable-mozilla

(訳者の環境では以下の様になりました。)

./configure --with-system-libs \
--without-system-jars --without-system-icu --without-system-agg \
--without-system-lpsolve --without-system-mspack --disable-mozilla \
--without-stlport

See the last information box in the configure script or Category:Distribution-Specific_Build_Instructions for more information for your platform.
お使いのプラットフォームの詳細については、 configure スクリプトの末尾の情報欄か Category:Distribution-Specific_Build_Instructions(英語) を見てください。

Documentation caution.png Please check for any warnings emitted by the configure-script.
configure スクリプトが出す、すべての warnings(警告) をチェックしてください。

bootstrap / ブートストラップ

When configure finished successfully, run:
構成が成功したら、以下を実行します。

./bootstrap

to create the dmake executable required to build OpenOffice.org.
OpenOffice.org をビルドするために必要な dmake を作成します。

setting the environment / 環境の設定

When the configure script has been run successfully a file LinuxX86Env.Set.sh or LinuxX86-64Env.Set.sh was created[7]. Do this:
configure スクリプトが正常に実行されると、 LinuxX86Env.Set.sh または LinuxX86-64Env.Set.sh が作成されます。[8]

source LinuxX86Env.Set.sh

or

source LinuxX86-64Env.Set.sh

to set up the environment for the build[9].
ビルドのための環境をセットします。[10]

starting the build / ビルドの開始

Build the software by typing the following in $SRC_ROOT[11]:
$SRC_ROOT で以下を打ち込んでビルドを開始します。[12]

cd instsetoo_native && build --all

The building procedure will take at least an hour (on a 3 GHz Quad-Core with 8GB RAM without CCACHE). ビルドには、(3GhzのクアッドコアCPU,8GByteのメモリー,CCACHEなしで)少なくとも1時間かかるでしょう。
(訳注:3GHzのデュアルコアCPU,1GByteのメモリーを与えた仮想環境上で4時間30分近くかかりました。)

Partial Builds / 部分ビルド

There are two ways to do partial builds:
部分ビルドには2つの方法があります。

  • compatible
  • incompatible

Only do compatible partial builds if you know exactly what you are doing.
何を行っているのか正確に分かっている場合は、 compatible部分ビルドを行ってください。

Documentation note.png For more information, see Compatible Builds.
より詳しい情報は、 Compatible Builds(英語) を見てください。

rebuilding from a module (incompatible build) / モジュールの再ビルド(incompatible ビルド)

If you decide to change a module in an incompatible way, you will need to rebuild all modules depending on it (directly or indirectly):
incompatibleな方法でモジュールを変更する場合は、それ(直接的または間接的)に依存するすべてのモジュールを再ビルドする必要があります。

cd $SRC_ROOT/instsetoo_native
build --from $INCOMPATIPLEMODULE --prepare
build --from $INCOMPATIBLEMODULE

rebuilding a module (compatible build) / モジュールの再ビルド(compatibleビルド)

To rebuild a module you can delete all output directories with, rebuild and redeliver into the solver with:
以下のコマンドで、出力ディレクトリを削除し、モジュールを再ビルドして、 solverディレクトリに再出力します。

cd $MODULE
build --from $MODULE --prepare
build && deliver

A simple build in $SRC_ROOT/instsetoo_native will recreate the installation sets, provided all other modules have already been build.[13]
他のモジュールがすでにビルドされているなら、build は、簡単にインストールセットを $SRC_ROOT/instsetoo_native に再作成します。[14]


Documentation caution.png This does not check for incompatible modules. If unsure, use an incompatible build (see above).
これは、非互換のモジュールについてチェックしません。不確かなら incompatible ビルド(上記を参照) を行ってください。


Building a Module with Debug Information / デバッグ用の情報を含めてビルドする

To rebuild a module with debug information and additional assertions and checks, run:
デバック用の情報とアサーションを追加してモジュールを再ビルドするには以下を実行します。

cd $MODULE
build --from $MODULE --prepare # removes old output trees and solver
build debug=true --from $MODULE

Drop the newly created binaries into an existing installation. Building an installation set with them will not help, as binaries are stripped on packing by default.
新しく作成したバイナリをあらかじめインストールした物に上書きしてください。デフォルトでは、パッケージにするときにインストールセットは省かれます。

Tip.png For details, see Debugging.
詳しくは、Debugging(英語)を見てください。


Finding Installation Sets / インストールセットの場所

The english installation set will be located at $SRC_ROOT/instsetoo_native/unxlngi6.pro/OpenOffice/{deb,rpm,archive}/install/en-US/[15].
英語版のインストールセットは次の場所にできます。$SRC_ROOT/instsetoo_native/unxlngi6.pro/OpenOffice/{deb,rpm,archive}/install/en-US/[16].

Documentation note.png For 64-bit Linux it is unxlngx6.pro instead of unxlngi6.pro.

64bit Linux の場合は、 unxlngi6.pro ではなく、 unxlngx6.pro です。

Tips And Tricks / ヒントとテクニック

ccache

export CCACHE_DIR="some/place/with/space"
ccache -M 2G -F 100000
export CXX="ccache g++"
export CC="ccache gcc"

dependencies / 依存関係

nodep

If you set the environment variable nodep to TRUE, then dependency information files are not created - the build finishes faster.
環境変数のnodepTRUEを設定した場合は、依存関係情報のファイルを作成しないため、ビルドがより早く終わります。

Documentation caution.png But only enable that on a clean build. Once you have built OOo and then made modifications, unset the variable again to be on the safe side.
クリーンビルド時のみ、有効にしてください。一度、OOoをビルド作成した後で、それに変更を加える場合には、安全にビルドするために、この環境変数をセットしないで(unsetして)ください。

NO_HIDS

Similar to the nodep variable, this one prevents the generation of HIDs (Help IDs) that are mainly used for automated testing - if you only want to build OOo, you don't need those.
nodep変数と同様で、このパラメータは自動化したテストに使用するHIDs(Help IDs)の生成を抑制します。OOoをビルドしたいだけならば、このHIDsは必要ありません。

parallel builds / 並列ビルド

If you have a multiprocessor machine or similar, you can run a parallel build. There are two levels of parallelism - one operating on makefile (directory) level, the other one on the global level. The two levels of parallelism result from the two-step build procedure in the OOo build environment. The build script runs through all the directories it reads from the build.lst files in all modules and calls dmake for every directory.
マルチプロセッサー、または、類似するマシンを使用しているなら、並列ビルドができます。並列ビルドには2種類あります。一つは、makefile(フォルダ)レベル、もう一つはグローバルレベルです。2つのステップの手順で、それぞれのOOoの並列ビルドを行う環境を構築します。ビルドスクリプトは、全フォルダの全モジュールのbuild.lstファイルを読み込み、全てのフォルダに対してdmakeを呼び出します。

parallelism on the global level
グローバルレベルでの並列処理

For parallelism on the global level, you have to run build from $SRC_ROOT>/instsetoo_native with the -P<number> switch, for example:
グローバルレベルでの並列処理は、$SRC_ROOT/instsetoo_nativeで、-P<number>スイッチを付けてビルドを実行する必要があります。例えば、

build -P2

です。

This takes build how many dmake processes it is allowd to start in parallel.
すると、多くのdmakeプロセスが並列起動を許可されビルドを行います。

parallelism on the directory level
フォルダレベルでの並列処理

export MAXPROCESS=<numer or processes> 

This tells dmake how many targets it is allowed to build in parallel. When you don't use build.pl but build a single directory (single makefile), you can achieve the same with
これで、並列にいくつビルドできるかをdmakeに伝えます。build.plを使わずに1つのフォルダ(1つのmakefile)でのビルドで同じ事ができます。

dmake -P2

combining both levels
両方の組み合わせ

If you want to have parallelism on both levels, you can call
両方のレベルで並列処理を行いたい場合は、以下を実行します。

build -P2 -- -P2

"--" is a special build.pl parameter that passes every further parameters to the dmake processes it starts.
"--"は、dmakeの起動ごとに引数を渡す、build.plのスペシャルパラメータです。

Recommendation
推奨(おすすめ)

Experience tells that using the doubled number of cores in your machine is a good choice, using more threads does not make a big difference, except if the combined option is chosen. So even on single core machines using two threads will speed up the build considerably.
経験から使用しているマシンのCPUコア数の2倍を指定すると良いでしょう。組み合わせオプションを使う場合を除いて、これ以上のスレッド数を使用しても大きな違いは起こりません。その為、シングルコアのマシンではビルドを高速化するため、2つのスレッドを使用しています。

create prebuilt mozilla / あらかじめビルドされた mozilla を作成する

For the mozilla-components you have the choice to either build from mozilla sources, to use precompiled packages or to use system-mozilla (the one installed on your buildsystem, not everything might work, depending on the version you got installed). You can easily create your own version of the prepacked binaries if you wish to do so (either because you cannot use the official ones because of mismatch of compiler version used to build them/other technical reasons or because you want to use stuff you didn't build yourself). To do so:
mozillaコンポーネントをmozillaのソースからビルドした物か、あらかじめコンパイルされたパッケージを使うか、またはシステムのmoziila[17]から選択します。 ビルドに使用するコンパイラのバージョンが異なるため公式パッケージを使用できない場合や、その他の技術的な理由、または、それを使いたいので自分でビルドしなかった場合でも、独自のバージョンのビルド済みパッケージを簡単に作成できます。これを行うには、以下の作業を行います。

  • build the moz module from the mozilla sources
    mozillaのソースからmozモジュールをビルドします。
  • use --enable-build-mozilla when running configure and put the mozilla-source tarball to moz/download
  • configureを実行するときに--enable-build-mozillaを指定します。また、mozillaのソースのターボールをmoz/downloadに置きます。
  • in moz run dmake zip to create the zip files
    mozで、dmake zipを実行して、zipファイルを作成します。
  • you'll find the zips in {platform}.pro/zipped
    {platform}.pro/zippedでzipファイルを見つけることができます。

Copy them to a location of your liking. Now instead of using --enable-build-mozilla, use --disable-build-mozilla and copy the zips you created or downloaded to moz/zipped and these will be used when compiling. This will greatly reduce build-time (you save the time that would otherwise be spent on compiling mozilla).
これらを任意の場所にコピーします。 --enable-build-mozillaの代わりに--disable-build-mozilla<code>を使用します。そして、自分で作成した、または、ダウンロードしたzipファイルを<code>moz/zippedにコピーします。すると、コンパイルするときこれらが使用されます。 これによりビルド時間(これ以外の場合にmozillaをコンパイルするのにかかる時間)を大幅に削減できます。

See Also / 参考

(訳注:リンク先は英語です)


  1. Documentation note.png Should be in place with most Linux distributions. Note the there are currently some issues with X version 4.3.
  2. Documentation note.png ほとんどの Linux ディストリビューションで適切な場所にあるべきです。注意:現在、 X のバージョン 4.3 にはいくつか問題があります。
  3. Documentation note.png PAM should be installed by default on most linux distributions. You should only need to add the development package.
  4. Documentation note.png PAM は、ほとんどの Linux ディストリビューションに標準でインストールされています。あとは、開発用パッケージを追加するだけです。
  5. Documentation note.png The gtk2, jpeg and tiff libraries are not required if you disable the crash-reporter when running ./configure.
  6. Documentation note.png ./configure を実行するときに、クラッシュレポーターを無効にするのなら、 gtk2 や jpeg および tiff ライブラリは必要ではありません。
  7. Documentation note.png When you want to use tcsh instead of bash, you will need to use the file LinuxX86Env.Set instead:
     source LinuxX86Env.Set
     rehash

    If you do not use tcsh, it is better to delete that file, as it will get in the way for tab-completion sooner or later.

  8. Documentation note.png bash の代わりに tcsh を使用している場合は、代わりに LinuxX86Env.Set を使用します。
     source LinuxX86Env.Set
     rehash

    tcsh を使用していないなら、タブ補完の邪魔になるので、このファイルを削除する方が良いでしょう。

  9. By default, native packages (.deb/.rpm) will be build.
    Tip.png If you want to have something faster and easier to test:
    export FORCE2ARCHIVE=true

    This will create a tarball that can easily be unpacked and run anywhere.

  10. デフォルトでは、ネイティブパッケージ(.deb/.rpm) をビルドします。
    Tip.png もし、高速で簡単にテストをしたい場合は、
    export FORCE2ARCHIVE=true

    これは、どこでも簡単に解凍・実行できるターボール(tarball) を作成します。

  11. Documentation note.png You can also run:
    make

    but GNU make will just start build.pl. For details run:

    build --help
  12. Documentation note.png 代わりに以下を実行できます。
    make

    しかし、 GNU make は build.pl を開始するだけです。 詳細を見るには以下を実行します。

    build --help
  13. Documentation caution.png build --all would rebuild changed/missing files. However, it does not check for incompatible modules. If unsure, use build --from --prepare.
  14. Documentation caution.png build --all は、変更された、もしくは見つからないファイルを再ビルドします。しかし、非互換性のモジュールをチェックしません。不確かなら build --from --prepare を使用します。
  15. The en-US in the path names indicates that the localization is American English. This value corresponds to the language tags defined by RFC 1766 (Tags for the Identification of Languages). The German installation set will be located in a de subdirectory. This scheme holds true for all localizations you may have chosen explicitly.
    Tip.png Running the configure script with the --with-lang option will introduce the build of additional language resources. This switch accepts one or more RFC 1766 language tags as arguments. Check the value of the completelangiso macro in $SRC_ROOT/solenv/inc/postset.mk for all the currently supported language tags.

    Example:

    ./configure --with-lang="de fr"

    This enables the build of the localized German and French version. The environment variable WITH_LANG will then contain the language tags of the additional (en-US will always be build) languages.


    Documentation note.png If you build additional localized languages it is possible to generate Language Packs that contain only the changes needed to add the additional language to an OpenOffice.org of a different language. The following commands will generate language packs languages that were specified with the --with-lang switch during the configure phase.
    cd $SRC_ROOT/instsetoo_native/util
    dmake ooolanguagepack
    Documentation caution.png Note that you can only build the language packs after you have build the complete office with all selected languages.
  16. パスの en-US は、言語が米語であることを示します。この値は RFC 1766(言語識別のためのタグ) で定義された言語タグと対応します。 ドイツ語のインストールセットは、 de サブディレクトに作成されます。 これは、明示的に選択された全ての言語版に当てはまります。
    Tip.png configure スクリプトに --with-lang オプションを付けて実行すると追加の言語版もビルドします。このスイッチは一つまたは複数の RFC 1766 言語タグを引数にとります。 現在サポートされている全ての言語タグを見るには、 $SRC_ROOT/solenv/inc/postset.mk にある completelangiso マクロの値をチェックしてください。

    例:

    ./configure --with-lang="de fr"

    ドイツ語版とフランス語版のビルドを有効にします。環境変数 WITH_LANG は、追加の言語版の言語タグを含むでしょう(en-US は常にビルドされます)。


    Documentation note.png ある言語版の OpenOffice.org に他の異なる言語を加えたい場合、必要な部分だけを含むランゲージパックをビルドすることは可能です。以下のコマンドで 構成時に --with-lang スイッチで指定した言語のランゲージパックを作成します。
    cd $SRC_ROOT/instsetoo_native/util
    dmake ooolanguagepack
    Documentation caution.png 選択した言語版のofficeを完全ビルドしたにのみ、ランゲージパックをビルドできることに注意してください。
  17. Documentation note.png ビルドを行うシステムにインストールされているもので、インストールしたときのバージョンに依存するため上手く動作しないかもしれないもの
Content on this page is licensed under the Public Documentation License (PDL).




翻訳者:
Matayoshi

査読者:

Personal tools
In other languages