特殊:Badtitle/NS100:FirefoxNewVersion/MozillaBuilds

来自Ubuntu中文
Wikibot留言 | 贡献2010年5月19日 (三) 22:22的版本
(差异) ←上一版本 | 最后版本 (差异) | 下一版本→ (差异)
跳到导航跳到搜索

{{#ifexist: :FirefoxNewVersion/MozillaBuilds/zh | | {{#ifexist: FirefoxNewVersion/MozillaBuilds/zh | | {{#ifeq: {{#titleparts:FirefoxNewVersion/MozillaBuilds|1|-1|}} | zh | | }} }} }} {{#ifeq: {{#titleparts:FirefoxNewVersion/MozillaBuilds|1|-1|}} | zh | | }}

This page describes how to run Mozilla builds of Firefox in Ubuntu. This can be useful if you want to check whether a bug exists in upstream versions of Firefox, or if you prefer to run the official Mozilla releases.

Instructions

IconsPage?action=AttachFile&do=get&target=IconWarning3.png Unless you have a specific reason to run the Mozilla build, it's recommended to use the packages from the official Ubuntu repositories.>See the recommended procedure for getting Firefox.

Ubuntuzilla repository

An easy way of installing a Mozilla build is to use the Ubuntuzilla project repository. Ubuntuzilla is for ordinary users that want to use the latest Mozilla build as their default browser. The Ubuntuzilla project's repository contains .deb repacks of the unmodified official Mozilla builds of Firefox, Thunderbird, and !SeaMonkey. Just add the repository to your sources, and you'll be kept up to date on the latest Mozilla releases through the package manager. See the Ubuntuzilla website for details and usage instructions.

Manual Installation

The following instructions will install Firefox in your home directory, and will use a different profile for Mozilla and Ubuntu builds of Firefox.

  1. Go to the Firefox download page
  2. Download Firefox for Linux
  3. Extract the file you downloaded into `~/firefox` (e.g. by doing `tar jxf firefox*.tar.bz2 -C $HOME`)
  4. Make a backup of your `~/.mozilla` directory (e.g. by doing `tar zcPf ~/mozilla-backup-$(date +%s).tar.gz ~/.mozilla`)

Next, if this is the first time you have installed a Mozilla build, do the following:

  1. Run `~/firefox/firefox -ProfileManager` to start the Firefox profile manager
  2. Create a new profile called mozilla-build
  3. Make sure that the default profile is still selected
  4. Click exit to close the profile manager (do not start Firefox)
  5. Run the following shell script:
mkdir ~/bin
cat > ~/bin/firefox <<END
#!/bin/bash

exec "\$HOME/firefox/firefox" -P mozilla-build "\$@"
END
chmod 755 ~/bin/firefox

The `firefox` command in your `~/bin` directory will now run Firefox with the mozilla-build profile.

Uninstallation

  1. Delete the `~/firefox` directory and the `~/bin/firefox` file
  2. Run `firefox -ProfileManager` and delete mozilla-build

This completely uninstalls the Mozilla build of Firefox. If you install a Mozilla build in future, you will need to perform all of the instructions above, including the first time instructions.

Restore your old profile

To restore the backup of your profile, do the following:

  1. Close any open Firefox windows
  2. Rename `~/.mozilla` (e.g. `mv ~/.mozilla ~/.mozilla-broken`)
  3. Extract your archive (e.g. by doing `tar zxPf ~/mozilla-backup-``DATE``.tar.gz`

This will completely reset your Firefox profile to the point when you made the backup.

Rationale

There are many ways to run Mozilla builds alongside Ubuntu builds, depending on your needs. This section will discuss some of the choices made in the above instructions. The guide recommends that you back your Mozilla profile up. Regular backups are always recommended, especially before a major software upgrade. Special precaution is necessary here because new versions of Firefox can make backwards-incompatible changes to profiles. For example, you should avoid using Firefox 3 on a profile that's been used with Firefox 3.5<<FootNote(http://irclogs.ubuntu.com/2009/07/08/%23ubuntu-mozillateam.html (search for profile damage))>>. The guide recommends extracting Firefox into your home directory. This is because extracting to another location (such as `/usr/local`) would require super-user permissions, without any benefit in the single-user case. If you want to provide new versions of Firefox on a multiple-user system, you are urged to use the recommended procedure. Installing non-Ubuntu software on a multi-user system massively increases your administrative burden - for example, you put your users at risk unless you manually update programs every time there's an update. The guide recommends that you create a `mozilla-build` profile for the downloaded version of Firefox. This is partially because of the above-mentioned compatibility issues, and partially because debugging Firefox is much easier with a fresh profile.