- 1 Profile
- 2 Projects
- 3 Software
- 4 Building Firefox
- 5 Tunneling a VNC session
James Boston is a Computer Programmer.
Blog & homepage:
mozilla [at] jamesboston [dot] ca
jboston on irc://irc.mozilla.org/seneca
Project page: Fixing nsIProcess
The API in Firefox for managing external processes has never been fully implemented. This project aims to implement the existing API and extend the API to include inter-process communication.
The Canvas 3D JS Libary (C3DL)
Project page: C3DL
canvas 3d WebGL. (Mozilla's Canvas 3D project has been superseded by the new WebGL standard that will also by used by WebKit.) It will provide a set of math, scene, and 3d object classes to make the canvas more accessible for developers that want to develop 3D content in browser.
Mozilla Developer Resource Kit
Project page: Mozilla Developer Resource Kit
Creating a package that contains everything a developer needs, including documentation, to get started with Firefox. The plan is to make it available as a live Fedora DVD for developers in countries where bandwidth is scarce.
This project is of uncertain status. It's a multi-semester project that is worked on by a new student group each semester, but it doesn't appear to be under development at this time.
Project page: Portable DXR
This is closely related to the MDRK. The aim is to package the Mozilla developer documentation and the DXR source browsing tool in an extension that can be easily distributed/installed mostly likely as a XUL/Prism application. As an added bonus, this is a group project where the team members are experimenting with using traditional project planning tools and open source development methods.
This project is defunct. It was a group project for school and some members have graduated. Plus, the nominal client in not interested in completion.
Process Manager Extension
A binary XPCOM extension that allows processes external to Firefox to be started and stopped. Currently only Win32 is supported. It is used in the SHTTPD extension.
Further notes on usage: http://jamesboston.ca/cms/node/41
This is a proof of concept. Installing this extension will start a tiny webserver that runs locally. The purpose of this is to eventually provide a way to distribute web application as extensions so they can be run locally/offline. At present, when the browser starts the server also starts and installs an icon to the system tray. It only runs on Win32 machines.
(The server is licensed as beerware and is available on its own at http://shttpd.sourceforge.net/).
Open in Editor Extension
This extension will open source code files from http://mxr.mozilla.org in an editor on the users machine. Simply right click on the loaded page and select the Open in Editor option from the pop up context menu. The user may choose any editor through preference settings. If no preferences are selected the extension defaults to gedit on Linux, notepad on Windows, and (currently) nothing on OS X.
Install Visual Studio:
(The Visual C++ 2008 Express version will work.)
If you paid for the Professional version of Visual Studio you can skip this step. But if you are using an express version, you need to install the Windows Server 2003 Platform SDK in order to get some headers (atlbase.h to be specific) included in the Professional version:
- On the above page, DO NOT click the web install link. Scroll further down the page to see a list of download options. You probably want PDSK-x86.exe for a 32-bit machine.
Install the Microsoft Windows Software Development Kit Update for Windows 7 (even if you are using Vista or Visual Studio Professional):
If you had a previous version of the SDK installed (such as the Vista SDK) open the CMD shell (Start-> All Programs-> Microsoft SDK v7.0-> CMD) and make sure the new version is set as default by entering:
Download and install Mozilla Build, a package of software prerequisites:
(If you get a message saying this application did not install properly then you should see a windows dialog giving you the option to re-install with the 'correct settings'. After that all should be well.)
To open a shell window click:
(The example above is for Visual C++ 2008 Express. The name of the bat file you use should match the directory that Visual Studio is installed in. For instance, VS2005 uses start-msvc8.bat)
Special note: You might get an error saying you are targeting the wrong SDK. Try deleting your obj-ff directory if you have one.
Install build pre-requisites for Fedora:
su -c "yum groupinstall 'Development Tools' 'Development Libraries' 'GNOME Software Development'" su -c "yum install mercurial autoconf213"
Additional Fedora 11 pre-requisites:
su -c 'yum install libnotify-devel'
Additional Fedora 10 pre-requisites:
su -c 'yum install libXt-devel'
Install Firefox 3 build pre-requisites for Ubuntu 8.10 and 9.04:
sudo apt-get install build-essential sudo apt-get build-dep firefox sudo apt-get install mercurial libasound2 libasound2-dev curl libcurl4-gnutls-dev libnotify-dev
You should have Xcode installed. You don't need to use Xcode for editing source files, but you will need the developer SDK that comes with it.
In order to build Firefox you will need something called MacPorts which can be downloaded from here:
After downloading and installing MacPorts you can then install the pre-requisites:
sudo port sync sudo port install mercurial libidl autoconf213
The build system should know to use autoconf 2.13 instead of later versions automatically, but on some *nix systems it may be necessary to specify it manually:
Or on some systems you may need to set AUTOCONF this way instead:
You need to create a hidden file for the build system that contains instructions on how you want your build completed.
Create and open a hidden file called .mozconfig in your home directory using notepad or gedit or vim:
Add the following lines to .mozconfig
# My first mozilla config . $topsrcdir/browser/config/mozconfig mk_add_options MOZ_OBJDIR=@TOPSRCDIR@/obj-@CONFIG_GUESS@ # Comment the next 2 lines for non-debug builds ac_add_options --disable-optimize ac_add_options --enable-debug
If you are using a multi-core computer for building, you can try adding a flag to speed up compile times. Use a value of ((# of cores)*2)+1 (ie. five for two cores):
For OS X (Leopard) add:
Getting the source
If you are attempting to build Firefox 3.1 or greater you can checkout the source using mercurial as described below. When creating a working directory and checking out the source it doesn't really matter where you put it, but avoid paths that contain spaces. Spaces in the path name will cause the build to fail. For Windows XP users, your home directory path almost certainly has spaces. If that is the case, just put the mozilla directory in your root (ie. C:\mozilla) and put the .mozconfig file in that directory. If your user name doesn't have space you can checkout the source to your home directory like this:
cd mkdir mozilla cd mozilla hg clone http://hg.mozilla.org/mozilla-central/ src
It is still possible to checkout older versions of Firefox using cvs:
cd cvs -d :pserver:firstname.lastname@example.org:/cvsroot co mozilla/client.mk cd ~/mozilla make -f client.mk checkout MOZ_CO_PROJECT=browser
Starting the build
You need to change to the directory that contains the source code and then run the make command:
cd ~/mozilla/src time make -f client.mk build
Special Fedora 11 note
You may need to patch the source before building because of a bug in Breakpad that shows up with the latest version of gcc (which F11 uses).
Patch and details here: https://bugzilla.mozilla.org/show_bug.cgi?id=485019
Running the build
Once the build is finished you should set the following environment variable to turn-off assertion dialogs:
When you run your build for the first time, create and select a new profile called "development" (or any name of your choice) to avoid corrupting your current profile.
Windows and Linux:
Updating a build
If you need to refresh the source code:
cd ~/mozilla/src hg pull -u
Rebuilding the browser
If you want to rebuild the entire browser just repeat the instructions for starting the build above. However, it is possible to do incremental builds where only the source code you have changed is compiled.
For instance, to rebuild after a change in the xpcom module try:
make -C ~/mozilla/src/obj*/xpcom
Or as a more general form:
make -C [the object directory corresponding to the source directory that has changed]
In most cases this will relink the changes and create a new browser binary. But there's no hard and fast rule about when you can successfully do an incremental build. Sometimes you can burrow a few levels into the object tree and sometime you need to build from the very top. It may take a bit of trial and error to discover what works.
Tunneling a VNC session
Some of the Mac minis in the ORI area at Seneca are configured to accept VNC connections, but without an SSH tunnel are too slow to be useful. These instructions will help you get setup.