Compiling SVN builds of Media Browser.

Posted by Jon | HTPC,Tips, Tricks & Guides | Thursday 5 March 2009 10:46 am

I see this asked so many times that I wanted to post a small guide that might help some of you poor souls along.  I will try and make this as simple as possible, but I cannot guarantee that you still won’t run into issues since any number of things can cause it to go wrong.  At least you will know how to do it if you want.

What you need:

  1. An SVN client.  I use TortoiseSVN and recommend that you do too since that is what I will be using.  Get it here (take note that there is an x86 and x64 build, so get what you need).
  2. WIX 3.0 beta (Windows Installer XML).  Get it here (again, x86 and x64 versions and it does matter).  Get whichever of the setup.zips that apply to you.
  3. Microsoft Visual C# 2008 Express Edition.  If you already have full Visual Studio and know how to use it, then you don’t need this guide in the first place.  Otherwise, get this here.
  4. Media Center SDK 5.3.  I’m not 100% sure that this is required, but I would get it in order to save yourself many headaches if it is.  Get it here.

Install everything, using defaults.  If you are unsure about anything during the installs, still use the defaults.  You will be forced to reboot after a couple of these, so just install everything and then reboot to save yourself some time.

When you come back up, go to a convenient directory location and create a new directory.  Call it MediaBrowser.  Right click on this folder and choose SVN Checkout.  The TortoiseSVN Checkout window will open and you want to put http://videobrowser.googlecode.com/svn/trunk/ (we are only working with the main supported trunk – no specialty branches) in the URL of repository: space.  Click OK and it will start downloading the trunk.

download.jpg

Once the download is complete, we can open Visual C# and open our newly downloaded project file.  Click File->Open Project and then browse to your MediaBrowser folder and open the MediaBrowser.sln file.  You will probably get an error along the lines of a csproj file not being supported, but this is no big deal.  Click OK and continue on.  On the far right, under Solution Explorer, your new project files will be laid out.  Click on the very top Solution ‘MediaBrowser’ (2 projects) and hit your F6 (build) key.  You will probably see some warnings listed in the Error List pane at the bottom, but if you look at the status bar once it is complete, you should see Build succeeded.  If your build failed, sorry.

build.jpg

You can now close VC# and browse over to your MediaBrowser folder.  You’ll want to go to MediaBrowser\MediaBrowser\Setup.  In there, you will find a Build.bat file.  This batch file will need to be run with administrator priviledges, so do whatever you need to do in order to get that done (if you’re not already an administrator).  When you execute the batch, you will see a command prompt window executing the scripts necessary to build your MSI file.

wix.jpg

Once WiX has finished creating your file, navigate to MediaBrowser\MediaBrowser\bin\Release and you should see your setup.msi file in there.

msi.jpg

Congratulations!  You’re done!  Before you ask, the answer is “yes”.  This is how you do any branch of the SVN.  If you’re even remotely crafty, you’ll be able to figure out how to get any of the other branches from the Google Code site for Media Browser.

Update:

The new SVN builds are much different and have different compilation requirements.  I have some updated instructions here.

Update2:

SVN is no longer used by the Media Browser team as they have switched to Google Code’s rendition of Mercurial.  The instructions in this post and the update them above no longer apply to retrieving data via subversion.  You will need TortoiseHg in order to grab source.

  • Share/Bookmark

No Comments »

No comments yet.

RSS feed for comments on this post. TrackBack URI

Leave a comment