문제

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.

도움이 되었습니까?

해결책

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

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top