Redhatas4 compilation of several original code packages
Source: Internet
Author: User
Article Title: redhatas4 compilation of several original code packages. Linux is a technology channel of the IT lab in China. Includes basic categories such as desktop applications, Linux system management, kernel research, embedded systems, and open source.
Non-genuine AS4 can not download the update package, we can only go to the ftp://updates.redhat.com/enterprise/4AS/en/ OS /SRPMS directory to download src. rpm to compile. Most packages can be compiled smoothly, but it takes some effort to compile the following packages.
1 thunderbird-1.0.2-1.4.1.src.rpm
Direct rpmbuild -- rebuild thunderbird-1.0.2-1.4.1.src.rpm can be compiled smoothly, but is unable to install prompt
Error: unpacking of archive failed on file/usr/lib/thunderbird-1.0.2/defaults/pref/all-redhat.js; 42ae6fc9: cpio: MD5 sum mismatch
Solution:
Modify the line 146-147 of the thunderbird. spec file:
Code:
% {__ Cat }%{ SOURCE10} | % {__ sed}-e's, THUNDERBIRD_RPM_VR, % {version}-% {release }, g' | % {__ sed}-e's, COMMAND, % {tbdir}/open-browser.sh, G'> rh-default-prefs
Then you can use rpmbuild-ba thunderbird. spec to install the node smoothly.
2 comps-4AS-0.20050525.src.rpm
This file is very troublesome, because it is the redhat release version, which records the comps file of the release version (that is, the categories we see in the Package Manager) and file header information, and we believe that there is no redhat compilation and packaging directory on the machine, so we cannot find the need to compile this package. discnfo, hdlist, hdlist2, and comps. xml. I used a work und to compile a new comps file using the original comps file of the system, because I am not very familiar with the production of the release version, I am not sure if this will affect system-config-packages in the future. At least I have not found any problems in my system after the upgrade.
Solution:
Cd/usr/share/comps/i386
Cp. discinfo ../..
Rpm-ivh comps-4AS-0.20050525.src.rpm
Rpmbuild -- define = "basedir/usr/share/comps/i386" -- define = "compsversion 4AS"-ba comps-redhat.spec
Compilation is successful.
It doesn't matter if this package is upgraded or not, but I don't want to see the red light when rh is upgraded.
3 rpmdb-redhat-4-0.20050525.src.rpm
This package needs to modify the specs file or it cannot be compiled.
Rpm-ivh rpmdb-redhat-4-0.20050525.src.rpm
Vi/usr/src/redhat/SPECS/rpmdb-redhat-rhel4.spec.in Addition
% Define rpmdbtree/usr/src/redhat/RPMS
% Define rpmdbname redhat
% Define rpmdbversion 4
In addition, you must:
Code:
Cat >$ {RPM_BUILD_ROOT }%{_ sysconfdir}/rpm/macros. solve <
# The path to the dependency universe database. The default value
# Is the rpmdb-redhat location. The macro is usually defined in
#/Etc/rpm/macros. solve, installed with the rpmdb-redhat package.
% _ Solve_dbpath/usr/lib/rpmdb/% {_ arch}-% {_ vendor}-% {_ OS}/redhat
# The path to the dependency universe packages. This shocould
# Be a path to the packages contained in the solve database.
% _ Solve_pkgsdir/var/spool/up2date
# The output binary package file name template used when suggesting
# Binary packages that solve a dependency. The macro is usually defined
# In/etc/rpm/macros. solve, installed with the rpmdb-redhat package.
#
# XXX Note: escaped % for use in headerSprintf ()
% _ Solve_name_fmt % {? _ Solve_pkgsdir }%%%{ NAME}-%%%{ VERSION}-%%%{ RELEASE}. %%%{ ARCH}. rpm
EOF
Code:
Cat >$ {RPM_BUILD_ROOT }%{_ sysconfdir}/rpm/macros. solve <
# The path to the dependency universe database. The default value
# Is the rpmdb-redhat location. The macro is usually defined in
#/Etc/rpm/macros. solve, installed with the rpmdb-redhat package.
% _ Solve_dbpath/usr/lib/rpmdb/% {_ arch}-% {_ vendor}-% {_ OS}/redhat
# The path to the dependency universe packages. This shocould
# Be a path to the packages contained in the solve database.
% _ Solve_pkgsdir/var/spool/up2date
# The output binary package file name template used when suggesting
# Binary packages that solve a dependency. The macro is usually defined
# In/etc/rpm/macros. solve, installed with the rpmdb-redhat package.
#
# XXX Note: escaped % for use in headerSprintf ()
% _ Solve_name_fmt % {? _ Solve_pkgsdir }%%%{ NAME}-%%%{ VERSION}-%%%{ RELEASE}. %%%{ ARCH}. rpm
EOF
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.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service