packageInstallation: Rpm-rebuild *.src.rpm Cd/usr/src/dist/rpms Description: The rpm--rebuild *.src.rpm command compiles the source code and generates a binary RPM package under/usr/src/dist/rpms, and then installs the binary package. Packgename as mentioned earlier, the two methods are as follows:FA 1:rpm-i your-package.src.rpmcd/usr/src/redhat/specsrpmbuild-bp your-package.specs #一个和你的软件包同名的specs文件cd/usr /src/redhat/build/your
In the words "Automake: from C to make", I started with a C language source code file and made a standard tar package.
How do I make an RPM package with a bar bag?
I have learned how to make RPM packages by referring to Linuxfans.org's article, "the RPM package principle (update 2010.11.22)". The following will show the process. establish a development environment first need software such as compilers
Yum Groupinstall "Development Tools"
and then do a little bit of the RPM configuration
E
Recently a lot of friends asked how to make the RPM package, you can not compile the other server on the software directory complex to other servers directly apply and so on ... Here is a simple introduction, advanced complex does not.
This method uses Rpmbuild to complete an RPM package by writing a spec file.
Take Nginx as an example to introduce
Production platform: CentOS 5.x x86_64
Four Step walk:
The first step: building the directory structure
MKDIR/USR/SRC/REDHAT/{SOURCES,
Run File hints:
/usr/local/tools/fetion:/lib/libgcc_s.so.1:version ' gcc_4.2.0 ' not found (required by/usr/local/tools/fetion/lib/ libstdc++.so.6)
View/lib/libgcc_s.so.1 file exists, is a link
[Root@localhost tools]# Ll/lib/libgcc_s.so.1
lrwxrwxrwx 1 root 28 March 08:16/lib/libgcc_s.so.1-> libgcc_s-3.4.3-20041213.so.1
View the GCC version of the system is gcc (GCC) 3.4.3
[Root@localhost ~]# gcc--version
GCC (gcc) 3.4.3 20041212 (Red Hat 3.4.3-9.el4)
So want to upgrade GCC, did not find gcc_4.2.
Compile Fedora kernel from src RPM package for Fedora 8 and later versions
Reference Http://fedoraproject.org/wiki/Docs/CustomKernel
All of the following commands are run under a non-root user
preparatory work
Before you begin, make sure that the following necessary packages are installed on the system:
Yum-utils
Rpmdevtools
The following command can be used to install:
Su-c ' yum install yum-utils rpmdevtools '
Where Yum-utils package provides Yumdownloader and YUM-BUILDDEP these two
information.
Just one place in the code. Note that each data is converted to lowercase when the signature is generated.
At the end of this section there is demo download.
Successful Data acquisition
When looking at the log output below the information, I know already victory in sight, integrated so many interfaces, the process is almost the same, a few hours to get it, of course, to achieve all the interface, so that orders run up, there is a lot of work to do, and so on the back of the emp
This is the first technical blog that I wrote on CSDN, because I have recently been working on RPM packaging. Share it today. The advantage of RPM is that installation and post-upgrade are quick and easy, eliminating the need to manually compile the source code again. Save a lot of time. Here the Nginx Server installation package is tested for an instance.
Environment:
1. System: CentOS release 6.5 (Final) x86_64
2. Hardware: KVM virtual machine, dual core cpu,2g memory, 50G HDD
3.user: Using
-ba xx.spec #生成rpmbuild目录以及子目录[[email protected] ~]# ls rpmbuild/BUILD buildroot RPMS SOURCES SPECS SRPMSSOURCES: directory where source packages are storedSPECS: Configuration file (basic information, source installation)BuildRoot: Rhizoids (for rpmbuild This software, packed under this root, does not affect the real root)RPMS: The position of the finished product, RPM package3) Prepare to copy the source software to the sources directoryIn the case
Some software packages end with. src. rpm. These software packages are rpm packages that contain source code and need to be compiled during installation. There are two ways to install such software packages:
Method 1:1. Execute rpm-I your-package.src.rpm2. cd/usr/src/redhat/SPECS3. rpmbuild-bp your-package.specs A specs file with the same name as your package4. cd/usr/src/redhat/BUILD/your-package/a directory with the same name as your package5 ../co
Require_distribution: 1
Vendor: twLUG
Require_vendor: 1
Packager: Penelope Marr
Additional important information
There are actually a lot of important details about the RPM Package File creation process, which must be kept in mind. please refer to [Building RPMs] in the RPM-HOWTO first.
4. a simple example
-=-
Let's start with a helloworld RPM Package File, which is easy to use. You can perform self-testing based on the entire example because they are small and simple and should not affec
Recompile the GCC-4.3.0-general Linux technology-Linux programming and kernel information, below is the details to read. GCC is a set of program compilers in Unix, including C, C ++, Fortran77, and Java. Upgrading GCC helps shorten the compilation process and generate more efficient programs, however, the compiled program may be large. the latest version is 4. 3. next we will start to install version 4.3.
First of all, make sure that your Unix environment has the compiling language. The system
Make RPM package, can be convenient for future maintenance. Unify the standard
Yum Install RpmdevtoolsAfter installation, use the Rpmdev-setuptree command to create the directory structure of the RPM package. The default is under $home under Rmpbuild, or it can be configured by ~/.rpmmacros.
Spec documentation is the core of making RPM packages.
Here's the copy from Fedora.
create a new. spec file now, you need to~/rpmbuild/specs directory,
Some software packages end with. SRC. rpm, which includes
Source codeThe RPM package must be compiled during installation. There are two ways to install such software packages:
Method 1:1. Execute rpm-I your-package.src.rpm2. CD/usr/src/RedHat/specs3. rpmbuild-BP your-package.specs A specs file with the same name as your package4. CD/usr/src/RedHat/build/your-package/a directory with the same name as your package5 ../configure this step is the sam
.
Note: You can go to www.kernel.org to download the kernel source code of a certain version. However, after downloading and compiling, You need to replace (install) The fc14 kernel image,
In this way, the kernel module compiled with the kernel source code of this version will pass smoothly in the insmod of the local machine.
Run
Rpm-uvh kernel-2.6.35.6-45.fc14.src.rpmRun
Cd/root/rpmbuild/SPECS
Note: fedora14 uses/root/rpmbuild as the main directory
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.