Feeds:
Posts
Comments

Archive for the ‘firefox’ Category

Well, the big ball ‘O duct tape that is my hacks on symbolstore.py are complete for now – here is the patch. This project will be carried on in the next term at which point I hope to address some of the current issues, namely – manipulating the directory structure, cleaning up the python code and assembling a unified documentation page.

For now – you may test out the fruits of my labour by downloading this installer of Firefox 3.0b2pre which will install Minefield in your Program Files/Minefield directory (you have no choice for installation dir.) and then copying these symbols into the folder where your Visual Studio (or Windbg) is looking for debug symbols.

The last thing you have to do in order for this to work is to put a path to cvs.exe in your PATH – I personally pointed it to the mozilla-build/mysys/bin/cvs.exe but if you like you can download cvs.exe and put it wherever you want.

Now that you have all you need, open up your debugger (VS or Windbg), attach it to the Minefield process and go!

It will ask you about the cvs calls that gather up the source code, say “OK” or “Run” or whatever is positive. The file should download into the proper /mozilla/whatever structure – on my computer it goes into Program Files/Microsoft Visual Studio 8/Common7/IDE/mozilla/…

That will be a focus in the next round, is manipulating the cvs command so that the source files go to a c:/temp or something. The debugger will automatically want to look for the path that the source file originally came from (in this case, my c:/ff_clean/mozilla/…) – you will have to point your debugger to the correct file the first time and then after that it knows to look in the mozilla folder you selected.

It works for now like what it is; a ball of duct tape that allows you to get the right source code for where you are in the browser without having a build on your computer.

I look forward to feedback about how this works for you, if you use it and if you have any problems arise.

Read Full Post »

Here is the code I have so far in symbolstore.py
http://pastebin.mozilla.org/254868

My portion is specifically lines 36 – 71 where I am now gathering up a string of source files along with the revision number, and generating a (almost) properly formatted stream file in the pdb’s directory.

Here are the barriers:

1. I would prefer to have a template where I have a variable %SOURCEFILES% that can be replaced and output to a new file for each pdb, instead of writing out each line of the stream file in symbolstore.py. If I can’t get that happening for this release – oh well, Dave said it can be a bit ugly at the 0.3 stage. At least what I have right now, is creating the stream file properly.

2. On lines 38 and 39 – what I am making here is a string that looks like this: c:\mozilla/xpcom/glue/nsTraceRefcnt.h and in fact, this has to be c:\USERS_SOURCEFILE_DIR\mozilla\xpcom\glue\nsTraceRecnt.h — so two things need to happen here, first, I need the / to be \ (except for the one after c:, cause it’s right already) and second, for now I can probably name the dir “ff” and the user can make sure that VStudio is pointing to that path (c:\ff) when looking for source files…but in the long run? I don’t know yet.

3. This is along the same lines as the template issue. The reason I haven’t successfully implemented the template is because I don’t know where to put, or how to create a path to, the right folders when symbolstore.py is being called. Unfortunately, it is not as easy as I had hoped in that putting the template in the same folder as symbolstore.py would allow me to open it with its name only. So as well as not being able to open the template, I don’t know how I can call upon pdbstr from inside of symbolstore.py

That’s going to be the last part, the first two are a little more pressing.

Read Full Post »

Here are the goals for my 0.2 release

  • release build of ff with debugger-info enabled to create pdbs without being a full debug build
  • using lib xul – make an installer for people to download
  • take the symbols and index them and distribute the source
  • set up the symbol server but indexed so that someone can pull the source code
  • which involves running the cv2http.cmd on the indexed code

And the results:

How to set up the Source and Symbol Server

  1. add a path to my symbolServer http://avnerd.tv/symbols/2007110200 as per MDC docs in Tools->Debugging->Symbols

  2. check the option for turning on the source server in Tools->Debugging->General

  3. Download the installer from here Firefox Installer **(FYI you have to use my installer because it is the one that I indexed code and uploaded symbols for – if you do not use this installer you will not get the proper results)
  4. install the firefox you just downloaded (it will install as Minefield in Program Files\Minefield)
  5. make sure you run it with –no-remote and -profilemanager so you don’t mess up your normal Firefox experience
  6. once it’s running, go to Tools->attach to process… and attach VStudio to the firefox instance
  7. after it’s attached, you can go to Debug->break all and then poke around at the firefox functions code (You will get a warning about downloading code from an unknown source, click on “run” because you trust me)

This is what it might look like:

Contribution Opportunity

You need to be in the Windows platform and have a copy of Visual Studio to run the above instructions. If this applies to you, please take a minute to download the installer and follow the instructions as I’ve outlined them.

Please leave a comment answering the following questions:

  1. Did it work for you?
  2. Were the instructions clear?
  3. Any constructive feedback?

Read Full Post »

Well today I got to run Full Functional Tests on Firefox 3 beta 1 and then this evening as I procrastinated from dealing with my Hamiltonian circuit assignment, I ran tests on Miro’s 1.0rc release.

The two testing systems are very different even though they both use Litmus-based testing. Miro’s tests are fewer, some are not well written and in some ways I find them to be very superficial. The Firefox tests have been around a lot longer so I’m sure that has allowed for quite a bit of fine tuning.

I’m not giving up on Miro but so far it’s been challenging to get involved with that project to the degree with which I have been able to immerse myself in Mozilla projects. The lab the other day threw me into Thunderbird in a quick ‘n dirty way and that was great – the documentation is all there. With Miro – well…when I went to look for docs on how to build with Windows…this and this. The gist of it is: “We can’t really tell you how to build on windows because it’s hard”.

Well, now that I’m working on the Mac Book and I have VMWare Fusion with an Ubuntu vm, perhaps I can try building it in a Unix/Linux environment? There’s a doc for Mac OS X and for Linux. We’ll soon see.

Now, back to Mozilla stuff. My 0.2. release is due soon, I have already done a non-debug build of FF with the –enable-debugger-info-modules in the mozconfig and I’ve made the buildsymbols for it. Now I just have to index the pdb files and get the symbols and the source up on my server. Immediately after that is done (in the next day or two) I will look into a) how to make an installer and b) how to work with the CVStoHTTP script that comes with the srctools.

When I have an installer up, I’ll be putting out the contrib call for anyone who can to grab the installer and try to hook it up with my symbol and source servers.

Stay tuned.

Read Full Post »

For my 5 hours between classes on Friday. Hopped into Litmus and joined in on Test Day. Managed to do 58 tests and filed my first bugs: 402219, 402228, and 402238.

I feel very accomplished. It’s fun to find a bug, and I had an especially great crash that I was able to reproduce 3 times, and after Vlad’s talk yesterday I am also looking forward to working on a patch and fixing a bug.

The past few days I have also been testing the waters over at Miro. What a difference size makes. Miro has only 11 staff – how many does Mozilla have? I would guess at least 20 or 30 times more. So far I haven’t done a build of Miro yet, I’m going to work on that over the weekend. Can’t wait to look at the source code and see what makes a video player. The funny (and somewhat frustrating) thing is that I have had to create new bugzilla and litmus accounts for Miro as my Mozilla ones don’t carry forward. Someone hurry up and get that OpenID stuff working on everything!

Read Full Post »

Here’s what we’re looking at.

I built a version of ff that was checked out from mozilla’s cvs. From this version I called “make buildsymbols” and created the folder 2007092823 which contained all the pdb and symbol files for that build.

For information on how to use the symbol server – check out Benjamin Smedbergs blog. Instead of pointing VStudio to the mozilla symbol server, I wanted to point to a local server of symbols.

In order to test whether these symbols worked, I set up IIS on my laptop and served up the pdbs locally to make sure that Visual Studio was able to pull them properly. After a quick detour to set up the MIME types on my server, this worked just fine.

Then I used the indexing tools that come with the microsoft.com/whdc/devtools/debugging/default.mspx Debugging for Windows package.

First – using cvsindex.cmd and pointing out the symbol path and the source path, the pdb files are then indexed with the location of the source code for that build.

Second – using srctools.exe I pulled a sample list of the source files that are contained in a pdb file

All of this is available in a zip file – PDB files and sample source list and I look forward to feedback from anyone who wants to look at the sample source list and discuss how the next step of connecting the cvs to the local pdb files might work. Also you can go to my wiki page to sign up as a contributor or to read more.

At the moment this will not work for someone who is debugging unless they have my build of FF. That’s what 0.2 is all about.

Read Full Post »

Today’s class was a presentation with Mark Finkle from Mozilla Corp. These are my notes.

Started off in proprietary software
Has only been with Mozilla for a year
The joy of extensions
– Primary way to get involved is through add-ons (extensions)
– Plug-ins killed the web (according to some) and are kind of discouraged
– Any app that uses the mozilla platform can be enabled to use extensions
– There’s built in support in the UI, cross platform, platform APIs

Sometime people put their content in a .jar and then in the .xpi necessary for installation. Mark doesn’t not advocate for this method because it can make things more confusing to new developers than need be.

He suggests keeping things as simple as you possibly can. Don’t use jar files, multiple levels, keep manifests simple. Don’t mimic other extensions that are often written by more experienced programmers.

Ted (:luser) has created a xul editor that can generate the skeleton for you, and if you use this then you have everything you need – just add content.

Use the pages on the MDC about the boilerplate aspects of creating extensions.

Stressed the importance of using the id of the rid firefox element to add your customized elements. Otherwise they may show up as document.getElementByID but they will not in fact appear. They will be in the ether until you merge them properly with the id. Examples are vbox id=”appcontent” or statusbar id=”status-bar”. Not merging properly is 90% of what people get stuck on when working on the UI elements of their application and it’s often that they are not using the id properly, don’t have the proper id or a syntax error.

Best Slide: “Mozilla is like an Onion: It makes you cry, it smells, it has layers”

Mozilla’s Tech Layers (1. XUL/JS/CSS, 2. XBL, 3. XPCOM)

Talking about layers he tells us that the top layer (the UI) is the easiest to get involved with and make changes to, but it’s also the least documented and has no API. Whereas the XPCOM layer is clean and documented and has APIs so in some ways it’s great to work with because it’s designed to be extensible.

A demo follows about trying to dig into the code via DOM inspector.

Google searching hint – put MDC in the search criteria to help narrow the results.

Highlighting of the Code Snippets section in MDC which can really help point you in the right direction.

Thanks for coming and talking with us Mark. I look forward to working on extensions in the future.

Read Full Post »

Older Posts »