Difference between revisions of "Assignment1(jbmossop)"
(One intermediate revision by the same user not shown) | |||
Line 1: | Line 1: | ||
− | + | === Steps Taken to Build the Fox === | |
---- | ---- | ||
By following the directions on David’s site for building Firefox as well as the documentation provided by Mozilla I was able to compile Firefox with little complication. In order for me to build Firefox on my machine I first needed to download the iso’s for Visual Studio 2005 from [http://acs.senecac.on.ca/pages/index.php ACS]. In addition to Visual Studio I also needed to install Cygwin, ensuring that the patchutils (version 3.80), perl, cvs, zip, and unzip packages are installed along with it. | By following the directions on David’s site for building Firefox as well as the documentation provided by Mozilla I was able to compile Firefox with little complication. In order for me to build Firefox on my machine I first needed to download the iso’s for Visual Studio 2005 from [http://acs.senecac.on.ca/pages/index.php ACS]. In addition to Visual Studio I also needed to install Cygwin, ensuring that the patchutils (version 3.80), perl, cvs, zip, and unzip packages are installed along with it. | ||
Line 11: | Line 11: | ||
With everything in place I entered the command to compile. After approximately 50 minutes (on a 1.7 GHz Celeron w/1gig ram) the build completed successfully. | With everything in place I entered the command to compile. After approximately 50 minutes (on a 1.7 GHz Celeron w/1gig ram) the build completed successfully. | ||
− | '''Fig 1: Config Batch File''' | + | ''' Fig 1: Config Batch File ''' |
---- | ---- | ||
<pre> | <pre> | ||
Line 49: | Line 49: | ||
</pre> | </pre> | ||
− | '''Fig 2: Mozconfig File''' | + | ''' Fig 2: Mozconfig File ''' |
<pre> | <pre> | ||
. $topsrcdir/browser/config/mozconfig | . $topsrcdir/browser/config/mozconfig | ||
Line 60: | Line 60: | ||
mk_add_options MOZ_CO_PROJECT=browser | mk_add_options MOZ_CO_PROJECT=browser | ||
</pre> | </pre> | ||
+ | |||
+ | === Software Installed === | ||
+ | ----- | ||
+ | *[http://acs.senecac.on.ca/pages/index.php Visual Studio 2005] | ||
+ | *[http://www.cygwin.com/ Cygwin] | ||
+ | |||
+ | === Problems Encountered === | ||
+ | *Unable to download the source tree from Mozilla’s cvs servers. | ||
+ | *Unsuccessful build using David’s mozconfig (Sister said it was done so she closed the Window). There were no executables in the bin directory after the process was completed so I assumed it had failed. | ||
+ | |||
+ | === Solutions to Problems === | ||
+ | *Found a [http://releases.mozilla.org/pub/mozilla.org/firefox/releases/1.5.0.6/source/ link to the source code] on the Mozilla website and downloaded it via the releases.mozilla.org site. | ||
+ | *Checked the [http://developer.mozilla.org/en/docs/Windows_Build_Prerequisites Mozilla prerequisite site] and used the mozconfig provided by them (I just wanted to get a build complete and did not want to wait another 40 minutes for a build that I was unsure as to whether or not it would complete successfully) | ||
+ | |||
+ | === Resources Used === | ||
+ | *[http://www.cygwin.com/ Cygwin] | ||
+ | *[http://cs.senecac.on.ca/~david.humphrey/writing/firefox-win32-build.html David Humphrey's Firefox Build Site] | ||
+ | *[http://developer.mozilla.org/en/docs/Windows_Build_Prerequisites Mozilla's Windows Build Pre-Requisites] | ||
+ | *[http://releases.mozilla.org/pub/mozilla.org/firefox/releases/1.5.0.6/source/ Firefox Source Code] | ||
+ | |||
+ | === Screenshots === | ||
+ | [[Image:Capture_09102006_221953.jpg]] | ||
+ | |||
+ | === Conclusion === | ||
+ | I was actually surprised at the sheer size of the source code for Firefox and the fact that through a few commands all of it would come together to form a very versatile program. In the past the largest program I had created was around 15,000 lines of code in VB6 at the time I thought it was a daunting achievement. It has really been enlightening to build this program and to actually be able to poke around in the source code. Overall I thought it would have been a lot harder to compile such a large program and I feel that the experience (though frustrating) was worth while. |
Latest revision as of 19:45, 19 September 2006
Contents
Steps Taken to Build the Fox
By following the directions on David’s site for building Firefox as well as the documentation provided by Mozilla I was able to compile Firefox with little complication. In order for me to build Firefox on my machine I first needed to download the iso’s for Visual Studio 2005 from ACS. In addition to Visual Studio I also needed to install Cygwin, ensuring that the patchutils (version 3.80), perl, cvs, zip, and unzip packages are installed along with it.
After installing VS2005 and Cygwin, I downloaded and extracted the moztools package to a temporary directory (c:\proj) in which I would be compiling the program. After logging onto the Mozilla cvs repository I successfully checked out the build script for Firefox.
Next I created a batch file (as per the instructions on David’s site) to set the environment variables for the Windows command prompt that would be needed to build Firefox (Fig 1) as well as a .mozconfig file to configure the settings for the build. I used the mozconfig provided by Mozilla on their website (Fig 2).
I next attempted to download the source tree from Mozilla’s cvs server and was unsuccessful. Therefore I obtained a copy of the Firefox source from Mozilla’s resource site and extracted it to my project directory.
With everything in place I entered the command to compile. After approximately 50 minutes (on a 1.7 GHz Celeron w/1gig ram) the build completed successfully.
Fig 1: Config Batch File
@echo off rem --- CVS Setup SET CVSROOT=:pserver:anonymous@cvs-mirror.mozilla.org:/cvsroot SET CVS_RSH=ssh set NSIS=C:\Program Files\NSIS rem --- Setup the paths to the moztools build libraries set MOZ_TOOLS=C:\proj\moztools set GLIB_PREFIX=%MOZ_TOOLS% set LIBIDL_PREFIX=%MOZ_TOOLS% rem --- Scrub these variables first SET INCLUDE= SET LIB= SET PATH=C:\;C:\windows\system32;C:\windows\system32\wbem rem --- Prepend cygwin SET PATH=C:\ffbuild\preReq\cygwin\bin;%PATH% rem --- Setup VC8 compiler environment vars CALL "C:\Program Files\Microsoft Visual Studio 8\VC\vcvarsall.bat" x86 rem --- Add glib/libidl to build environment SET PATH=%PATH%;%GLIB_PREFIX%;%GLIB_PREFIX%\bin SET INCLUDE=%GLIB_PREFIX%\include;%INCLUDE% SET LIB=%GLIB_PREFIX%\lib;%LIB% rem --- moztools comes last after glib/libIDL SET PATH=%PATH%;%MOZ_TOOLS%\bin set path=%PATH%;%NSIS%
Fig 2: Mozconfig File
. $topsrcdir/browser/config/mozconfig mk_add_options MOZ_OBJDIR=@TOPSRCDIR@/ff-opt-static ac_add_options --enable-optimize ac_add_options --disable-debug ac_add_options --enable-static ac_add_options --disable-shared ac_add_options --disable-tests mk_add_options MOZ_CO_PROJECT=browser
Software Installed
Problems Encountered
- Unable to download the source tree from Mozilla’s cvs servers.
- Unsuccessful build using David’s mozconfig (Sister said it was done so she closed the Window). There were no executables in the bin directory after the process was completed so I assumed it had failed.
Solutions to Problems
- Found a link to the source code on the Mozilla website and downloaded it via the releases.mozilla.org site.
- Checked the Mozilla prerequisite site and used the mozconfig provided by them (I just wanted to get a build complete and did not want to wait another 40 minutes for a build that I was unsure as to whether or not it would complete successfully)
Resources Used
- Cygwin
- David Humphrey's Firefox Build Site
- Mozilla's Windows Build Pre-Requisites
- Firefox Source Code
Screenshots
Conclusion
I was actually surprised at the sheer size of the source code for Firefox and the fact that through a few commands all of it would come together to form a very versatile program. In the past the largest program I had created was around 15,000 lines of code in VB6 at the time I thought it was a daunting achievement. It has really been enlightening to build this program and to actually be able to poke around in the source code. Overall I thought it would have been a lot harder to compile such a large program and I feel that the experience (though frustrating) was worth while.