Using apt in an RPM world
来源:互联网 发布:2015年中国统计数据库 编辑:程序博客网 时间:2024/05/22 14:57
from: http://dag.wiee.rs/blog/using-apt-in-an-rpm-world
Everytime I am surprised that people don't know that apt-get works on RPM-based distributions and works much better than the alternatives. Especially in a CentOS/RHEL environment where you have various distribution releases running, apt-rpm allows you to use the same apt version and the same apt features across CentOS/RHEL 2.1, 3, 4 and 5.
In an attempt to persuade you to try out apt, let me denounce some myths about the current apt-rpm:
- works on RPM packages
- can do multilib (coexist 32bit and 64bit)
- does check GPG keys on packages
- can work with repomd repositories (as used by yum)
- does work a lot faster than yum
- is being maintained (although could use more hands)
- has python bindings
- has a graphical interface (synaptics)
- handles multiple repositories much better
- allows to pin packages by version or repository (and manages cross-dependencies)
- existed years before yum (and was the only depsolver for a few years in the Red Hat world)
Now, because I can say it works great but you may not believe me, let me make it very simple for you to try it out on CentOS. Here is a quickstart guide...
First we start off installing apt from RPMforge. Follow the guide on the CentOS wiki to configure RPMforge for your system. Then do:
yum install apt
(or alternatively install the latest apt RPM package from http://packages.sw.be/apt/for your distribution)
and then edit the file /etc/apt/sources.list.d/os.list and add for CentOS:
repomd http://mirror.centos.org/ centos/$(VERSION)/os/$(ARCH)
repomd http://mirror.centos.org/ centos/$(VERSION)/updates/$(ARCH)
repomd http://mirror.centos.org/ centos/$(VERSION)/extras/$(ARCH)
This adds the official CentOS os, updates and extras repositories.
Now you can use it, for example do:
apt-get update
to update the locally cached metadata, or do:
apt-get upgrade
to upgrade your system with the latest updates, or yet, do:
apt-get install synaptic
to install a package named synaptic. Try:
synaptic
to start synaptic and use the graphical interface (also available from System > Administration > Synaptic Package Management)
There are a few commands that use the locally cached metadata, the following apt-cache commands are used most often:
apt-cache search keyword
to search the local metadata for packages related to keyword, or:
apt-cache policy package
to show the different versions of a certain package that is offered.
PS And let me also add that the project name is apt-rpm, not apt4rpm (a complete different project).
- Using apt in an RPM world
- Warning:Using incompatible plugins for the annotation processing: android-apt. This may result in an
- Using Theme in an Application
- Using Theme in an Application
- Project Management in an Agile World
- Using MySQL in an OpenBSD Environment
- Using ASIHTTPRequest in an iOS project
- Using Core Plot in an iPhone Application
- invoking an exe using javascript in firefox
- RPM APT-GET
- Creating an Interactive 3D World in C#.NET
- Practices of an Agile Developer : Working in the Real World
- Open Source Compiles in an Xcode 5.1 World
- python 递归实例(recursion in real world using python)
- ODB hello world example using PostgreSQL in windows
- Using Java in scientific research Part one: An introduction
- Using an Input Method Editor in a Game
- An easy instance of using the template class in C++
- Objective-C消息机制的原理
- 猎豹免费wifi校园神器 v2.0.140227 校园网专版
- how to install scikit-learn
- c#.net在Web页中设置Cookies
- 想要主框架与子框架的菜单项有相同的响应函数
- Using apt in an RPM world
- 3
- 按一定长度截取utf-8编码的字符串
- StringBuffer vs StringBuilder
- PHP判断一个请求是AJAX请求还是普通请求
- 解决Redhat Linux5 yum出现This system is not registered with RHN的方案
- linux下安装java
- oracle常用函数汇总
- 浅谈动态库技术