「Free Pascal パッケージガイドライン」の版間の差分
表示
削除された内容 追加された内容
ページの作成:「Category:パッケージ開発 en:Free Pascal package guidelines {{Package Guidelines}} このページでは [http://freepascal.org Free Pascal Compiler (FPC)]...」 |
同期 |
||
| 3行目: | 3行目: | ||
{{Package Guidelines}} |
{{Package Guidelines}} |
||
このページでは [http://freepascal.org Free Pascal Compiler (FPC)] でビルドされるソフトウェアの [[PKGBUILD]] を書く方法を説明しています。 |
このページでは [http://freepascal.org Free Pascal Compiler (FPC)] でビルドされるソフトウェアの [[PKGBUILD]] を書く方法を説明しています。{{Pkg|fpc}} パッケージはホスト CPU (i686 または x86_64) を対象にしたコンパイラを提供します。 |
||
==== Arch Linux ==== |
|||
* {{Pkg|fpc}} is available in the official Arch community repository and provides a compiler targetting only your host CPU (i686 or x86_64). |
|||
* {{AUR|fpc-multilib}} is available from the [[Arch User Repository]] which provides an x86_64 host compiler targetting both i686 and x86_64 CPU Linuxes. This will also provide the {{AUR|ppcross386}} FPC compiler driver package. |
|||
==== クロスコンパイラ ==== |
|||
* {{AUR|fpc-arm-android-rtl}} for ARM-based Android (beta) |
|||
* {{AUR|fpc-arm-linux-rtl}} for ARM-based Linux |
|||
* {{AUR|fpc-arm-wince-rtl}} for MS Windows CE |
|||
* {{AUR|fpc-i386-android-rtl}} for 32-bit Intel based Android (beta) |
|||
* {{AUR|fpc-i386-freebsd-rtl}} for 32-bit Intel FreeBSD |
|||
* {{AUR|fpc-i386-win32-rtl}} for 32-bit MS Windows |
|||
* {{AUR|fpc-powerpc-linux-rtl}} for 32-bit PowerPC-based Linux |
|||
* {{AUR|fpc-sparc-linux-rtl}} for SPARC-based Linux |
|||
* {{AUR|fpc-x86_64-win64-rtl}} for 64-bit MS Windows |
|||
== Free Pascal == |
== Free Pascal == |
||
=== パッケージの命名規則 === |
=== パッケージの命名規則 === |
||
プロジェクトの名前だけで十分です。 |
|||
The project name alone is usually sufficient. However, in the case of cross-compiling, the package should be prefixed with {{Ic|fpc32-}} when targetting i686 Linux from multilib and named in the format of {{Ic|fpc-''cpu''-''system''-''pkgname''}} when targetting non-Arch Linux systems. |
|||
=== 便利なスニペット === |
=== 便利なスニペット === |
||
* FPC のバージョンとユニットの CPU と OS を確認するには: |
|||
* Determine FPC's version and the CPU and OS of the units to output: |
|||
_unitdir=`fpc -iSP`-`fpc -iSO` |
_unitdir=`fpc -iSP`-`fpc -iSO` |
||
_fpcver=`fpc -iV` |
_fpcver=`fpc -iV` |
||
=== パッケージング === |
=== パッケージング === |
||
FPC ベースのパッケージを作成する場合、以下の事柄に従ってください: |
|||
Please adhere to the following when making an FPC-based package: |
|||
* |
* {{ic|makedepends}} または {{ic|depends}} に常に {{Pkg|fpc}} を追加する |
||
* |
* コンパイル済みのファイル (*.a, *.compiled, *.o, *.ppu, *.res, *.rst) は常に {{ic|/usr/lib/fpc/''$_fpcver''/units/''$arch''-linux}} に保存する |
||
* |
* インポートライブラリをインストールする場合は {{ic|staticlibs}} を {{ic|options}} に追加する |
||
==== クロスコンパイル ==== |
|||
* always add the corresponding cross compiler package mentioned above ({{Ic|fpc-''cpu''-''system''-rtl}} or {{AUR|fpc-multilib}} for multilib) to {{ic|depends}} |
|||
* always add {{ic|!strip}} to {{ic|options}} for non-Unix-based systems |
|||
* always put all compiled units (*.a, *.compiled, *.o, *.ppu, *.res, *.rst) under {{ic|/usr/lib/fpc/''$_fpcver''/units/''$_unitdir''}} (or if multilib, {{ic|/usr/lib/fpc/''$_fpcver''/units/i386-linux}}) |
|||
* always use {{ic|any}} ({{ic|x86_64}} if multilib) as the architecture |
|||
* add {{ic|staticlibs}} to {{ic|options}} if installing an import library |
|||
2017年3月15日 (水) 00:59時点における版
パッケージ作成ガイドライン
32ビット – CLR – クロス – Eclipse – Electron – Free Pascal – GNOME – Go – Haskell – Java – KDE – カーネル – Lisp – MinGW – Node.js – ノンフリー – OCaml – Perl – PHP – Python – R – Ruby – Rust – VCS – ウェブ – Wine
このページでは Free Pascal Compiler (FPC) でビルドされるソフトウェアの PKGBUILD を書く方法を説明しています。fpc パッケージはホスト CPU (i686 または x86_64) を対象にしたコンパイラを提供します。
Free Pascal
パッケージの命名規則
プロジェクトの名前だけで十分です。
便利なスニペット
- FPC のバージョンとユニットの CPU と OS を確認するには:
_unitdir=`fpc -iSP`-`fpc -iSO` _fpcver=`fpc -iV`
パッケージング
FPC ベースのパッケージを作成する場合、以下の事柄に従ってください:
makedependsまたはdependsに常に fpc を追加する- コンパイル済みのファイル (*.a, *.compiled, *.o, *.ppu, *.res, *.rst) は常に
/usr/lib/fpc/$_fpcver/units/$arch-linuxに保存する - インポートライブラリをインストールする場合は
staticlibsをoptionsに追加する