4 PATCHES - track and distribute your code changes
8 This page documents how to distribute your changes to
13 We would like to have unified context diffs with full
14 pathnames. A script automating supplied with Lily. Dis-
15 tributing a change normally goes like this:
17 o make your fix/add your code
19 o Add changes to NEWS, and add yourself to Documenta-
24 o e-mail your patch to one of the mailing lists gnu-
25 music-discuss@gnu.org or bug-gnu-music@gnu.org
29 In VERSION, set MY_PATCH_LEVEL:
35 In NEWS, enter a summary of changes:
41 Then, from the top of Lily's source tree, type
46 which rolls the tarball ../releases/lilypond-0.1.73.tar.gz
47 and leaves your patch as ./lilypond-0.1.73.jcn1.diff. [1]
48 We assume that there is a tarball lilypond-0.1.73.tar.gz in
49 the directory ../releases.
51 If you didn't configure Lily using --srcdir, you can do:
55 tar-ball: ../patches/lilypond-0.1.73.jcn1.gz
56 patch: ../patches/lilypond-0.1.73.jcn1.gz
57 updeet: ../test/updeet
61 For creating a patch you need
63 o All items mentioned in INSTALL. You're not going to
64 send a patch that you haven't even built, right?
68 o Python (version 1.5 or newer). You can of course make
69 a patch by hand, which would go something like:
72 [1] 'Make diff' generates a patch between two tar-
73 balls. For more info type 'make diff help=='.
77 diff -urN lilypond-0.1.73 lilypond-0.1.73.jcn1 > lilypond-0.1.73.jcn1
79 but there are handy python scripts available. If
80 you're doing development, you'll need Python for other
81 LilyPond scripts anyway.
83 o The Lily directory structure, which looks like:
85 doos/ # gnu/windows32 build and binary releases
86 harmonia -> harmonia-x.y.z
88 lilypond -> lilypond-x.y.z # symlink to development directory
89 lilypond-x.y.z/ # current development
90 patches/ # patches between different releases
91 RedHat/BUILD # RedHat build and binary releases
94 releases/ # .tar.gz releases
95 test/ # tarballs and diffs from current version
99 with prefix $HOME/usr/src and (for building rpms only)
102 topdir: /home/fred/usr/src/RedHat
106 If you're following LilyPond development regularly, you
107 probably want to download just the patch for each subsequent
108 release. After downloading the patch (into the patches
109 directory, of course), simply apply it:
111 gzip -dc ../patches/lilypond-0.1.74.diff.gz | patch -p1 -E
113 and don't forget to make automatically generated files:
115 autoconf footnote(patches don't include automatically generated files,
116 i.e. file(configure) and files generated by file(configure).)
122 If you're not very quick with sending your patch, there's a
123 good chance that an new release of LilyPond comes available.
124 In such a case, the maintainer will probably ask you to make
125 a new patch against the latest release. Your best bet is to
126 download the latest release, and apply your patch against
127 this new source tree:
130 gzip -dc ../patches/lilypond-0.1.73.jcn1.diff.gz | patch -p1 -E
134 Then, make a patch as shown above.
142 Han-Wen Nienhuys <hanwen@cs.uu.nl>
144 Just keep on sending those patches!