个人工具

UbuntuHelp:OtherWaysToInstall

来自Ubuntu中文

Wikibot讨论 | 贡献2007年11月30日 (五) 20:56的版本

跳转至: 导航, 搜索

Warning

Installing is not always straight forward. A program may require additional packages from the repositories or libraries to be compiled as well. Therefore if you require a program, search the repositories first. Installing a package from the repositories is the easiest and fastest method of installation.

Lots to Install

There are plenty of popular packages in Ubuntu. However not all packages are visible after the install. It would involve an awful lot of software being installed that is not needed for basic functionality. AddingRepositoriesHowto

Installing the standard ways

In Ubuntu there are several standard ways to install software. Usually that involves a tool called "Synaptic Package Manager" or the command line tools "apt-get", or "dpkg". These are dealt with elsewhere. SynapticHowto AptGetHowto ( http://linuxhelp.blogspot.com/2005/12/concise-apt-get-dpkg-primer-for-new.html )

Compiling

You can compile software on Ubuntu or any other GNU/Linux distro. Before you proceed you need to install the build-essential package. This contains everything required for compiling on any Ubuntu version to work. It is not part of the default install. To install either use synaptic, or via the command line apt-get.

sudo apt-get install build-essential

To obtain the sources for any package you want to modify on Ubuntu by installing the source from the repos in ubuntu. This is can be done in synaptic by enabling sources and by modifing /etc/apt/sources.list by hand see SourcesList. This next part is adapted from the apt-get man page: "apt-get source" causes apt-get to fetch source packages. If the --compile options is specified then the package will be compiled to a binary .deb using dpkg-buildpackage, if --download-only is specified then the source package will not be unpacked. Note that source packages are not tracked like binary packages, they exist only in the current directory and are similar to downloading source tar balls. "apt-get build-dep" causes apt-get to install/remove packages in an attempt to satisfy the build dependencies for a source package.

Packaging Issues

Taking packaged .deb file from random repositories and installing them on your machine if they are not build for your specific version of Ubuntu, they may work perfectly on some Debian or Kanotix build, but may fail on your own machine. The same can be said of using the "alien" package to convert rpms to .deb packages.

Compiling Issues

Compiling packages from source that were not adapted for use with your distro and the version you are running may cause you a little or a lot of pain.