diff options
Diffstat (limited to 'debian/README.source')
-rw-r--r-- | debian/README.source | 65 |
1 files changed, 65 insertions, 0 deletions
diff --git a/debian/README.source b/debian/README.source index 919b04f36..89e832305 100644 --- a/debian/README.source +++ b/debian/README.source | |||
@@ -39,6 +39,71 @@ repository in ~/src/debian/openssh/, upstream checkouts in | |||
39 | ~/src/debian/openssh/upstream/, and my own working trees in | 39 | ~/src/debian/openssh/upstream/, and my own working trees in |
40 | ~/src/debian/openssh/trunk/. | 40 | ~/src/debian/openssh/trunk/. |
41 | 41 | ||
42 | Patch handling | ||
43 | -------------- | ||
44 | |||
45 | This package uses quilt to manage all modifications to the upstream source. | ||
46 | Changes are stored in the source package as diffs in debian/patches and | ||
47 | applied automatically by dpkg-source when the source package is extracted. | ||
48 | |||
49 | To configure quilt to use debian/patches instead of patches, you want either | ||
50 | to export QUILT_PATCHES=debian/patches in your environment or use this | ||
51 | snippet in your ~/.quiltrc: | ||
52 | |||
53 | for where in ./ ../ ../../ ../../../ ../../../../ ../../../../../; do | ||
54 | if [ -e ${where}debian/rules -a -d ${where}debian/patches ]; then | ||
55 | export QUILT_PATCHES=debian/patches | ||
56 | break | ||
57 | fi | ||
58 | done | ||
59 | |||
60 | After unpacking the source package, all patches will be applied, and you can | ||
61 | use quilt normally. | ||
62 | |||
63 | If you check out the source code from bzr, then all patches will be applied, | ||
64 | but you will need to inform quilt of this manually. Do this by running: | ||
65 | |||
66 | debian/rules quilt-setup | ||
67 | |||
68 | To add a new set of changes, first run quilt push -a, and then run: | ||
69 | |||
70 | quilt new <patch> | ||
71 | |||
72 | where <patch> is a descriptive name for the patch, used as the filename in | ||
73 | debian/patches. Then, for every file that will be modified by this patch, | ||
74 | run: | ||
75 | |||
76 | quilt add <file> | ||
77 | |||
78 | before editing those files. You must tell quilt with quilt add what files | ||
79 | will be part of the patch before making changes or quilt will not work | ||
80 | properly. After editing the files, run: | ||
81 | |||
82 | quilt refresh | ||
83 | |||
84 | to save the results as a patch. | ||
85 | |||
86 | Alternately, if you already have an external patch and you just want to add | ||
87 | it to the build system, run quilt push -a and then: | ||
88 | |||
89 | quilt import -P <patch> /path/to/patch | ||
90 | quilt push -a | ||
91 | |||
92 | (add -p 0 to quilt import if needed). <patch> as above is the filename to | ||
93 | use in debian/patches. The last quilt push -a will apply the patch to make | ||
94 | sure it works properly. | ||
95 | |||
96 | To remove an existing patch from the list of patches that will be applied, | ||
97 | run: | ||
98 | |||
99 | quilt delete <patch> | ||
100 | |||
101 | You may need to run quilt pop -a to unapply patches first before running | ||
102 | this command. | ||
103 | |||
104 | You should only commit changes to bzr with all patches applied, i.e. after | ||
105 | 'quilt push -a'. | ||
106 | |||
42 | Merging new upstream releases | 107 | Merging new upstream releases |
43 | ----------------------------- | 108 | ----------------------------- |
44 | 109 | ||