Contribute/Firefox: Difference between revisions

From MozillaWiki
Jump to navigation Jump to search
(Replaced content with "=Contributing to Mozilla Firefox= ==Step 0: Download and install the prerequisites== https://developer.mozilla.org/en-US/docs/Simple_Firefox_build")
Line 4: Line 4:


https://developer.mozilla.org/en-US/docs/Simple_Firefox_build
https://developer.mozilla.org/en-US/docs/Simple_Firefox_build
==Step 1: Download the code==
===1.1 Mozilla Firefox development uses Mercurial for code management.===
hg clone https://hg.mozilla.org/mozilla-central
This will create a folder called mozilla-central which holds all the necessary code to build firefox.
===1.2 Create a config file (optional)===
By default, you do not need one. However, the generated build will be an optimized build with no debug symbols. For a build that can be run under a debugger, you need a mozconfig file.
<pre>cd /path/to/mozilla-central
touch .mozconfig</pre>
Add options to the file:
https://developer.mozilla.org/en/docs/Configuring_Build_Options
Mozconfig example:
http://swarm.cs.pub.ro/~vgosu/mozilla/.mozconfig
===1.3 Build the code===
./mach build
===1.4 Run Firefox===
Linux/Windows: <code>./obj-[...]/dist/bin/firefox -P blank -no-remote</code>
OS X: <code>./obj-[...]/dist/Nightly.app/Contents/MacOS/firefox -P blank -no-remote</code> or <code>./obj-[...]/dist/NightlyDebug.app/Contents/MacOS/firefox -P blank -no-remote</code>
The extra arguments ensure that you use a different profile for development and allow you to continue using any existing Firefox instances.
==2. Create a Bugzilla account==
Go to https://bugzilla.mozilla.org/createaccount.cgi
Enter your email address. Confirm it, and login to bugzilla.
==3. Search for bugs / File bugs==
====Mentored bugs:====
These are tasks in our database for which there is a guaranteed mentor.
http://www.joshmatthews.net/bugsahoy/
====Good first bugs:====
https://bugzilla.mozilla.org/buglist.cgi?quicksearch=sw%3A[good%20first%20bug];list_id=5083823
====Student projects:====
https://bugzilla.mozilla.org/buglist.cgi?quicksearch=kw%3Astudent-project;list_id=5083824
====Recommended:====
For first timers, the best bugs are fixing warnings.
The next level would be telemetry bugs (just search for "add telemetry" on bugzilla)
If a bug doesn't exist, file one.
==4. Fix the bug==
This might tricky, especially for newbies.
If you don't know where you should start, first try posting on the bug and asking for more information.
The fastest way to get some information is to ask on the '''#introduction''' or '''#developers''' channels on [http://irc.mozilla.org irc.mozilla.org].
==5. Post the patch on bugzilla==
https://developer.mozilla.org/en-US/docs/Developer_Guide/How_to_Submit_a_Patch
===5.1 Who should review my code ===
https://wiki.mozilla.org/Modules/Core
Don't always list the module owner. The other peers will do a good job, and they have more spare time.
==6. Get feedback==
Make sure you follow the Coding Style:
https://developer.mozilla.org/en-US/docs/Developer_Guide/Coding_Style
==7. Announce that your work is ready to be committed==
When your patch is granted review+ by your reviewer, it's ready to be committed. If nobody commits it within a day or two, get in touch with your reviewer.
==8. Additional resources==
Warnings:
http://swarm.cs.pub.ro/~vgosu/mozilla/build_output.txt
=== MXR ===
MXR is the code browsing tool used by the Firefox.
http://mxr.mozilla.org/mozilla-central/
An alternative is DXR, which is supposed to be the a more evolved version of MXR.
http://dxr.mozilla.org/
=== MDN ===
Also known as Mozilla Developer Network, this is a good place to get more info about what you need to do.
https://developer.mozilla.org/en-US/docs/Introduction
You might also need a .hgrc file:
http://swarm.cs.pub.ro/~vgosu/mozilla/.hgrc
http://swarm.cs.pub.ro/~vgosu/mozilla/_my_bash

Revision as of 10:14, 14 December 2013

Contributing to Mozilla Firefox

Step 0: Download and install the prerequisites

https://developer.mozilla.org/en-US/docs/Simple_Firefox_build