dpkg-deb –build 的使用

測試環境

以下測試是在「Xubuntu 14.04 64位元」。

使用範例

「dpkg-deb –build」的使用範例,請參考『如何製作「deb檔(Debian Package)」』這篇。

手冊說明

$ man dpkg-deb

可以看到一段說明

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
-b, --build directory [archive|directory]
Creates a debian archive from the filesystem tree stored in directory. directory must have a DEBIAN subdirectory, which
contains the control information files such as the control file itself. This directory will not appear in the binary
package's filesystem archive, but instead the files in it will be put in the binary package's control information area.

Unless you specify --nocheck, dpkg-deb will read DEBIAN/control and parse it. It will check it for syntax errors and
other problems, and display the name of the binary package being built. dpkg-deb will also check the permissions of the
maintainer scripts and other files found in the DEBIAN control information directory.

If no archive is specified then dpkg-deb will write the package into the file directory.deb.

If the archive to be created already exists it will be overwritten.

If the second argument is a directory then dpkg-deb will write to the file package_version_arch.deb, or package_ver‐
sion.deb if no Architecture field is present in the package control file. When a target directory is specified, rather
than a file, the --nocheck option may not be used (since dpkg-deb needs to read and parse the package control file to
determine which filename to use).

$ man dpkg

可以看到一段說明

1
2
3
4
5
dpkg-deb actions
See dpkg-deb(1) for more information about the following actions.

-b, --build directory [archive|directory]
Build a deb package.