Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Including license agreement in .deb file

How can i include a license agreement interaction in a .deb file? The question Linux support for click-thru licenses only asks if its possible, but not how. Also, I'm not sure if license info of a deb package is actually something one could use...

I know it's possible to include the text as part of the package description, but I'd much rather have it similar to a Windows MSI installer.

Note that I don't want to have the license pop up the first time the application runs.

I'm using dpkg-deb to generate the .deb file on Ubuntu 8.10.

like image 532
Fredrik Ullner Avatar asked Jan 28 '10 12:01

Fredrik Ullner


People also ask

Are deb packages signed?

Signed packagesDebian-based distributions support GPG signature verification of signed Debian packages, but most (if not all) have this feature disabled by default. Instead packages are verified by signing the repository metadata (i.e. Release files).

What does a deb file contain?

Every DEB file consists of two TAR archives that make up the executable files, documentation, and libraries. It may or may not be compressed using GZIP, BZIP2, LZMA, or XZ. Similar to this format are micro deb files (. UDEB) that include some but not all the same information as a regular DEB file.


1 Answers

Put the question in the preinst script for your package, and if they answer incorrectly (or don't answer), exit the script with an error code and the package won't be installed.

The typical way to ask the user questions during package installation is with debconf. There are alternatives to debconf, including just using the bash read builtin. Debconf just makes it easy for you. There's a tutorial at http://www.fifi.org/doc/debconf-doc/tutorial.html

like image 153
Eric Warmenhoven Avatar answered Sep 20 '22 00:09

Eric Warmenhoven