documentation: dev-manual - Updates to Git workflow and kernel patch
I updated the sections on the "Git Workflow" in Chapter 4 and the "Patching the Kernel" section in Chapter 5 per Tom Zanussi's review comments. Minor technical changes. (From yocto-docs rev: fd8a291349c06328adebd37f8a9bbeaa49adb44c) Signed-off-by: Scott Rifenbark <scott.m.rifenbark@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
parent
205db48480
commit
450f438012
|
@ -1726,10 +1726,10 @@
|
||||||
</literallayout></para></listitem>
|
</literallayout></para></listitem>
|
||||||
<listitem><para><emphasis>Generate the patch file</emphasis>:
|
<listitem><para><emphasis>Generate the patch file</emphasis>:
|
||||||
This Git command creates the a patch file named
|
This Git command creates the a patch file named
|
||||||
<filename>0001-calibrate: Add printk example.patch</filename>
|
<filename>0001-calibrate-Add-printk-example.patch</filename>
|
||||||
in the current directory.
|
in the current directory.
|
||||||
<literallayout class='monospaced'>
|
<literallayout class='monospaced'>
|
||||||
$ git format-patch HEAD~1
|
$ git format-patch -1
|
||||||
</literallayout>
|
</literallayout>
|
||||||
</para></listitem>
|
</para></listitem>
|
||||||
</orderedlist>
|
</orderedlist>
|
||||||
|
@ -1776,7 +1776,7 @@
|
||||||
<literallayout class='monospaced'>
|
<literallayout class='monospaced'>
|
||||||
FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
|
FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
|
||||||
|
|
||||||
SRC_URI += "file://0001-calibrate: Add printk example.patch"
|
SRC_URI += "file://0001-calibrate-Add-printk-example.patch"
|
||||||
|
|
||||||
PRINC := "${@int(PRINC) + 1}"
|
PRINC := "${@int(PRINC) + 1}"
|
||||||
</literallayout>
|
</literallayout>
|
||||||
|
@ -1784,7 +1784,7 @@
|
||||||
statements enable the OpenEmbedded build system to find the patch file.
|
statements enable the OpenEmbedded build system to find the patch file.
|
||||||
</para></listitem>
|
</para></listitem>
|
||||||
<listitem><para><emphasis>Put the patch file in your layer</emphasis>:
|
<listitem><para><emphasis>Put the patch file in your layer</emphasis>:
|
||||||
Move the <filename>0001-calibrate: Add printk example.patch</filename> file to
|
Move the <filename>0001-calibrate-Add-printk-example.patch</filename> file to
|
||||||
the <filename>meta-mylayer/recipes-kernel/linux/linux-yocto</filename>
|
the <filename>meta-mylayer/recipes-kernel/linux/linux-yocto</filename>
|
||||||
directory.</para></listitem>
|
directory.</para></listitem>
|
||||||
</orderedlist>
|
</orderedlist>
|
||||||
|
|
|
@ -1705,7 +1705,7 @@ directory.</para></listitem>
|
||||||
<literallayout class='monospaced'>
|
<literallayout class='monospaced'>
|
||||||
$ git init
|
$ git init
|
||||||
$ git add *
|
$ git add *
|
||||||
$ git commit
|
$ git commit -m "initial revision"
|
||||||
</literallayout>
|
</literallayout>
|
||||||
The above Git commands initialize a Git repository that is based on the
|
The above Git commands initialize a Git repository that is based on the
|
||||||
files in your current working directory, stage all the files, and commit
|
files in your current working directory, stage all the files, and commit
|
||||||
|
@ -1762,9 +1762,9 @@ directory.</para></listitem>
|
||||||
Once the changes are committed, use the <filename>git format-patch</filename>
|
Once the changes are committed, use the <filename>git format-patch</filename>
|
||||||
command to generate a patch file:
|
command to generate a patch file:
|
||||||
<literallayout class='monospaced'>
|
<literallayout class='monospaced'>
|
||||||
$ git format-patch HEAD~1
|
$ git format-patch -1
|
||||||
</literallayout>
|
</literallayout>
|
||||||
The <filename>HEAD~1</filename> part of the command causes Git to generate the
|
Specifying "-1" causes Git to generate the
|
||||||
patch file for the most recent commit.</para>
|
patch file for the most recent commit.</para>
|
||||||
<para>At this point, the patch file has all your edits made
|
<para>At this point, the patch file has all your edits made
|
||||||
to the <filename>file1.c</filename>, <filename>file2.c</filename>, and
|
to the <filename>file1.c</filename>, <filename>file2.c</filename>, and
|
||||||
|
@ -1784,7 +1784,7 @@ directory.</para></listitem>
|
||||||
of the recipe.
|
of the recipe.
|
||||||
Here is an example:
|
Here is an example:
|
||||||
<literallayout class='monospaced'>
|
<literallayout class='monospaced'>
|
||||||
SRC_URI += "file://my_changes.patch"
|
SRC_URI += "file://0001-<commit-summary-message>.patch"
|
||||||
</literallayout></para></listitem>
|
</literallayout></para></listitem>
|
||||||
<listitem><para><emphasis>Increment the Recipe Revision Number:</emphasis>
|
<listitem><para><emphasis>Increment the Recipe Revision Number:</emphasis>
|
||||||
Finally, don't forget to 'bump' the
|
Finally, don't forget to 'bump' the
|
||||||
|
|
Loading…
Reference in New Issue