WdOS: a CentOS-based simplified and optimized Linux server system. It integrates web application environments such as nginx, apache, php, and mysql, and the wdcp management system, it is convenient to use the backend server and website management, FTP and database. it is easy to operate, secure, stable, and easy to use lamp...
WdOS: a CentOS-based simplified and optimized Linux server system. It integrates web application environments such as nginx, apache, php, and mysql, and the wdcp management system, it is easy to use, operate, secure, stable, and easy to use with backend management of servers and websites, FTP and databases. lamp, lnmp, and lnamp can be freely switched.
I. INTRODUCTION to checkinstall
II. installation of the Checkinstall tool
III. Checkinstall application example
I,About Checkinstall
Checkinstallis a program that can automatically generate the RPM/Debian or Slackware installation package from the source code of the tar.gz class. With checkinstall, you can use the source code of all the tar.gz classes to generate a "clean" installation or uninstall package. This problem often occurs: I think the program only has the source code (such as tar.gz) available, and no one provides RPM or Debian packages. You have to download the source code, decompress it, and then compile it manually. So far, everything is normal. However, what if you want to delete it? The Makefile file contains only a few unload routines. Of course, you can install the program to a temporary folder, write down all the files generated or modified by the program, and delete them. However, if this program needs to be re-compiled frequently, it will be very painful and the workload will be quite large. Checkinstall is used to solve this problem. Especially when the source code needs to be repeatedly compiled, CheckInstall allows you to completely uninstall the program without compromising system consistency.
Generally, the following steps are used to compile and install a program configured by GNU Autoconf:
./Configure & make install
Use CheckInstall to change to:./configure & make & checkinstall
II,Install Checkinstall
Before using the checkinstall tool to generate RPM packages, you must install the checkinstall tool.
Download the checkinstall source code package as follows:
Download(22.78 KB)
[Root @ wdOS src] # tar xzf checkinstall-1.6.0.tgz // extract the source package
[Root @ wdOS src] # cd checkinstall-1.6.0 // enter the default file directory generated during decompression
[Root @ wdOS checkinstall-1.6.0] # make
[Root @ wdOS checkinstall-1.6.0] # make install
[Root @ wdOS checkinstall-1.6.0] # checkinstall // generates the rpm Package for checkinstall
The process is as follows:
1,
Download(17.75 KB)
2,
Download(22.41 KB)
3,
Download(22.03 KB)
Check the RPM Package
Download(9.38 KB)
Install the RPM Package of checkinstall.
Download(10.65 KB)
Download(8.05 KB)
Modify the checkinstall configuration file
[Root @ wdOS i386] # vi/usr/local/lib/checkinstall/checkinstallrc
Download(18.67 KB)
Download(7.4 KB)
III,The Checkinstall tool creates an rpm package instance.
1. download the source code package
Download(24.75 KB)
2. rpm Package generation
[Root @ wdOS src] # tar-zxvf squid-2.7.STABLE7.tar.gz
[Root @ wdOS src] # cd squid-2.7.STABLE7
[Root @ wdOS squid-2.7.STABLE7] #./configure
[Root @ wdOS squid-2.7.STABLE7] # make
[Root @ wdOS squid-2.7.STABLE7] # checkinstall
(Note: The Command checkinstall not only runs make install by default, but also monitors all write operations during installation. Therefore, CheckInstall uses the program Installwatch written by Pancrazio de Mauro. After make install is complete, CheckInstall will generate an Slackware-, Debian-, or RPM-installation package, and then install the program according to the default configuration of the software package, and leave the generated installation package in the current directory (or the standard installation package storage directory .)
The Checkinstall tool generates the RPM Package. The process is as follows:
(1), (2), (3)
Download(19.72 KB)
(4)
Download(23.84 KB)
(5)
Download(11.72 KB)
This article is excerpted from wdlinux Forum http://www.wdlinux.cn/bbs reprint please note!