模板:Ubuntu:Feisty/UbuntuUpdates:修订间差异

来自Ubuntu中文
跳到导航跳到搜索
Oneleaf留言 | 贡献
New page: == Ubuntu Updates == ==== Apt, Software and Package Basics ==== *Read #General Notes *Read #How to add extra repositories Here is some basic information on how to use the Apt pa...
 
RegentW留言 | 贡献
第126行: 第126行:
Note: These are basic instructions that may not always work. Some packages require additional dependencies and optional parameters to be specified in order to build them successfully.
Note: These are basic instructions that may not always work. Some packages require additional dependencies and optional parameters to be specified in order to build them successfully.


==== How to manually update Ubuntu ====
==== 手动更新 Ubuntu ====


*Read [[#General Notes]]
*阅读 [[#概述]]
*Read [[#How to add extra repositories]]
*阅读 [[#如何添加额外的软件源]]


  sudo aptitude update
  sudo aptitude update
第135行: 第135行:
  sudo aptitude dist-upgrade
  sudo aptitude dist-upgrade


'''OR'''
'''或者'''


Use Update Manager: ''System -> Administration -> Update Manager''
用更新管理器: ''系统 -> 系统管理 -> 更新管理器''

2007年5月31日 (四) 23:04的版本

Ubuntu Updates

Apt, Software and Package Basics

Here is some basic information on how to use the Apt package management tools.

  • Installing packages
sudo aptitude install <packagename>

Examples:

sudo aptitude install mpd sbackup
  • Removing packages
sudo aptitude remove <packagename>

Examples:

sudo aptitude remove mpd sbackup
  • Searching for packages
sudo aptitude search <keywords>

Examples:

sudo aptitude search Music MP3
sudo aptitude search "Text Editor"
  • Updating Apt database (used after adding/removing Apt repositories)
sudo aptitude update
  • Upgrading packages
sudo aptitude upgrade
  • Upgrade entire distribution
sudo aptitude dist-upgrade
  • Install downloaded Ubuntu (Debian) package (.deb)
sudo dpkg -i package.deb
  • Remove Ubuntu (Debian) package
sudo dpkg -r package
  • Reconfigure/Repair installed package
sudo dpkg-reconfigure package

Examples:

sudo dpkg-reconfigure mpd
  • Handling ".tar.gz" (Tar/GZip) Archives

To extract:

tar xvzf package.tar.gz

To create:

tar cvfz package.tar.gz folder
  • Handling ".tar.bz" (Tar/BZip) Archives

To extract:

tar xvjf package.tar.bz

To create:

tar cvjf package.tar.bz folder
  • Extracting ".bz" Archives
bunzip2 file.bz
  • Extracting ".gz" Archives
gunzip file.gz
  • Building from Source

Make sure you have all the neccesary development tools (i.e. libraries, compilers, headers)

sudo aptitude install build-essential
sudo aptitude install linux-headers-`uname -r`

Extract your package (as detailed above)

tar xvzf package.tar.gz

Commence the build process

cd /path/to/extracted/package
./configure
make
make install

If build is successful, consider making an Ubuntu (Debian) package (.deb) for future use:

Install package tools:

sudo aptitude install checkinstall

Rebuild package using "checkinstall":

cd /path/to/extracted/package
./configure
make
checkinstall

Keep the resulting ".deb" file for future use. It can be installed using:

sudo dpkg -i package.deb

Note: These are basic instructions that may not always work. Some packages require additional dependencies and optional parameters to be specified in order to build them successfully.

手动更新 Ubuntu

sudo aptitude update
sudo aptitude upgrade
sudo aptitude dist-upgrade

或者

用更新管理器: 系统 -> 系统管理 -> 更新管理器