MDN’s new design is in Beta! A sneak peek: https://blog.mozilla.org/opendesign/mdns-new-design-beta/

Mozilla build用VMを使用する

この翻訳は不完全です。英語から この記事を翻訳 してください。

If you ever wondered what contributing to Firefox feels like but you never had the time to read and follow through our instructions to setup a build environment or wanted to avoid making changes to your standard tools and configuration, then this might be for you. Mozilla provides a virtual machine (VM) which is compatible with the free VirtualBox virtualization software (as well as others, including VMWare/VMWare Fusion).

This article provides simple instructions for downloading, installing, and setting up this build environment build machine; once you've finished following the steps below, you'll have a VM ready for you to modify and tweak Firefox.

Hopefully this VM will especially help developers or potential developers who don't have a full C++ development environment available to them, as well as to experienced developers without the time to set up a build system following the usual instructions.

Installing VirtualBox

Visit the VirtualBox downloads page and download the latest version of the software for your operating system.

Note: If you already have a virtualization product installed, such as VirtualBox, VMWare, or VMWare Fusion, you can use that instead of downloading a new copy of VirtualBox. Just make sure you have the latest version of the software. Note that Parallels Desktop does not support the OVF format.

VMのダウンロード

Next, download the Firefox development environment VM.

Download the VM

SHA-256: 67698e6dfe54582b4fc23221a8b8f3a9062ffa0bce11523823ccb26a8f8bce2b

Note: This file is about 3.6 GB, so it may take a while to download.

Setting up the VM

After getting the virtual machines' .ova file has downloaded, double-click on it; this will start the process of importing the VM into VirtualBox. Please give the VM a minimum of 4096 MB of RAM (8192 MB or more if you can), and set it to have the same number of processors as your host computer. Building Firefox uses a lot of system resources, and you want it to build as quickly as possible.

Screen shot of the Import Virtual Appliance window

Once you've finished importing the VM, you can perform additional customizations if you wish, or just boot the VM and wait for the Ubuntu desktop to appear. A terminal window will pop up automatically and perform some final setup activities. Once those are finished running, Sublime Text will start up, and you can get to work!

Screen shot of the Sublime Text editor running in the VM

Note: もしrootのパスワードが必要になった場合、 "firefox-dev" をパスワードとして使用することができます。 If you wish to change your language and keyboard settings, follow the instructions in How to change the UI language in Ubuntu.

Firefoxをビルドする

VMを使用してFirefoxをビルドするためには、(sublimetextを開いた状態で上のバーから)Toolsメニューを開きBuildオプションを選びます。ビルドの処理が開始するので、お茶や美味しい食事でもして休憩しましょう。休憩の長さはあなたのコンピューターの処理速度によります。

もしビルドが終了(完了)した場合、Tools内のRunオプションを選び、あなたがカスタムビルドしたfirefoxを起動させることができます。想定した動作をしているかどうか確認してみてください。

デフォルトではこのVMはFirefoxのビルドに最適化された設定になっています。デバッグ用ビルドに変更することもかんたんにできます。Toolsメニューを開き、Build Systemサブメニューを開いて、"Firefox (Debug)"を選ぶだけです。次にあなたがビルドするときはデバッグ用のビルドになっているでしょう!

Screen shot showing how to switch between debug; and optimized builds

VMでcontributeする

今後はあなたがどこにいてもVMを使ってcontributeすることができます。最新のソースコードを mozilla-central, 内から持ってくるには、いつものようにMercurialのコマンドを打つだけで済みます:

hg pull

そしていつもと同じように 作成したパッチを提出する こともできます。

Now what?

Now that you've successfully built Firefox in your brand-new VM, you might be wondering what to do next.  A great way to start is to pick a small, easy-to-fix bug and contribute code that patches it. Imagine how awesome it is to have code you wrote shipped to half a billion users all over the world!

Here are some links to help you find something you can do to make Firefox better:

  • Code Firefox Lessons provides a number of video tutorials for new Firefox contributors.
  • Bugs Ahoy! (a tool to help you find bugs that might interest you).
  • firefox-dev.tools (a tool to help you find bugs related to the Firefox Developer Tools that might interest you).
  • Developer guide (documentation about developing on and for Mozilla projects).
  • Mentored bugs have a mentor who commits to helping you every step of the way. Generally, there should be enough information in the bug to get started. Whenever you need help, contact the mentor over IRC, in the bug itself, or by email. When you've completed the bug, they will help you get your code into the tree.
  • "Good" first bugs may be a little stale, but at some point in their lives we considered that they would be a good first step for newcomers to Mozilla. We are in the process of migrating these bugs to mentored bugs, but more recent "good first bugs" may be good starting points if there are no appropriate mentored bugs.
  • How to submit a patch (information about how to create a patch file and get it submitted into the source code).

You can also ask your getting-started questions in #introduction, and any Firefox development questions in #developers.

ドキュメントのタグと貢献者

 このページの貢献者: lv7777
 最終更新者: lv7777,