To create an RPM package on a Linux system, create a shell script and a readme file. The readme file is primarily used as a comment and description for the shell script. This article will introduce the steps to create RPM packages for Linux systems.
RPM package to create a simple process
1. Create a directory structure, the RPM package file needed to be included. The name of this structure is usually named after the RPM package, including its version number. . We named this directory test-1.0. The following command tells you how to create and name this directory, how to put the required files inside:
$ cd /usr/src/redhat
$ mkdir test-1.0
$ cd test-1.0
$ echo echo this is a test 》 test.sh
$ chmod +x test.sh
$ echo just launch the Script README
2. Now, all the files needed for the RPM package are here. The next step is to create a .tar.gz file containing the RPM files. This directory also makes it easier to create archive files. The .tar.gz file needs to be located in a directory called rpmbuild/SOURCES. You also need a .specs file that contains all the specifications for creating an RPM package. The .specs file is the core component of the RPM package and includes instructions for all files. The files in the RPM package are installed according to these instructions. The .specs file should be placed in a SPECS directory.
The first cd command ensures that the rpmbuild directory is located in the current user's home directory. Execute the following command as a normal user:
$ cd
$ mkdir -p rpmbuild/SOURCES
$ mkdir -p rpmbuild/SPECS
$ Tar -cvzf rpmbuild/SOURCES/test-1.0.tar.gz test-1.0 Previous12Next page Total 2 pages
In the process of using Linux, we sometimes encounter the exhaustion of swap memory
Many users have encountered garbled problems when installing GBK or GB2312 on Linux system. This is
In China, users like to use Alibaba Cloud server, because this is the best cloud server in China, bu
When running Ubuntu system in Virtualbox virtual machine, it is sometimes necessary to implement int
Linux method for creating custom Docker images
Linux automatically generates a MAC address method summary
Linux recovery root password two methods
Ubuntu install Nox, compile make error, what should I do?
Introduction to Linux Process Knowledge
Linux off screen splash screen method
Linux installation of the appropriate kernel header file method
After Ubuntu restarts, how does the screen display the maximum brightness?
Ubuntu 12.04 via XRDP Remote Desktop Method
Win7 program can not start prompt LIBEAY32.DLL lost how to do?
How win8 download software installation in the app store
How to set the IE10 page display ratio in Win8 system
Setup does not accept Windows 10 upgrades are useless Microsoft will harass you every day
Easily uninstall multiple operating systems (1)
Win10 latest version 9879 will be released to "Slow Ring"
Win8 system and Linux share 8 features
Win10 Mobile mobile version 10.0.01010 multi-image exposure: detail adjustment a lot
Check the Win7 process path to ensure the security of the computer.