(cd gecko && git apply [the patch you downloaded])
Note: if <code>git apply</code> fails, you may need to use <code>patch -p1</code>.
Next, either copy the files <code>device/rpi/rpi/custom-settings.json</code> and <code>device/rpi/rpi/custom-prefs.js</code> in your <code>gaia/build/config/</code> directory, or --- if you already have custom settings or prefs --- append the contents of those files to your existing custom-* files.