-
-
Notifications
You must be signed in to change notification settings - Fork 2
Mono and Gerrit
Note: This page contains old documentation from 2011, but may still be useful to reference.
This page describes the new way of setting up for building our custom mono and how to submit patches.
Our custom mono consists of three git repositories: libgdiplus, mono, and mono-basic. The checkout-and-build-mono script will clone, update and build all three of them.
$ git clone git://git.lsdev.sil.org/mono-calgary.git $ cd mono-calgary mono-calgary$ ./checkout-and-build-mono
To submit patches it's easiest to work in a new branch. It's a good idea to name the branch after the JIRA issue you're working on:
$ cd mono mono $ git checkout -b FWNX-1234 calgary-2-10
You fix your bug and submit locally. Then you can upload your change to Gerrit for code review:
mono $ git review calgary-2-10
When the change is reviewed either the reviewer or you can submit the patch on the Gerrit website. You can then pull the latest changes and get rid of your working branch:
mono $ git checkout calgary-2-10 mono $ git pull origin calgary-2-10 mono $ git branch -d FWNX-1234
If we want to update our branch to newer changes in the official mono repo, it's easiest to add an "upstream" remote to our local git configuration:
libgdiplus $ git remote add upstream https://github.com/mono/libgdiplus.git
There are two options to do this:
1) Merge the changes from upstream to our branch
libgdiplus (calgary-2-10) $ git fetch upstream mono-2-10 libgdiplus (calgary-2-10) $ git merge upstream/mono-2-10 libgdiplus (calgary-2-10) $ git push origin calgary-2-10
2) Create a new branch and rebase our changes onto that
libgdiplus (calgary-2-10) $ git fetch upstream mono-2-12 libgdiplus (calgary-2-10) $ git checkout -b calgary-2-12 upstream/mono-2-12 libgdiplus (calgary-2-12) $ git rebase --onto mono-2-12 calgary-2-10 calgary-2-12 libgdiplus (calgary-2-12) $ git push origin calgary-2-12
To build packages for testing locally:
$ cd libgdiplus libgdiplus $ debuild -b -us -uc
mono-calgary $ make-source-package libgdiplus calgary-2-10
This will create two files fieldworks-libgdiplus_2.10-1.dsc and fieldworks-libgdiplus_2.10-1.git.