Merge lp:~jelmer/bzr-builddeb/no-trace-info into lp:~bzr-builddeb-hackers/bzr-builddeb/trunk-old
- no-trace-info
- Merge into trunk-old
Proposed by
Jelmer Vernooij
Status: | Merged |
---|---|
Merge reported by: | James Westby |
Merged at revision: | not available |
Proposed branch: | lp:~jelmer/bzr-builddeb/no-trace-info |
Merge into: | lp:~bzr-builddeb-hackers/bzr-builddeb/trunk-old |
Diff against target: |
411 lines 6 files modified
builder.py (+5/-5) cmds.py (+19/-19) directory.py (+5/-5) hooks.py (+2/-2) import_dsc.py (+2/-2) upstream.py (+16/-16) |
To merge this branch: | bzr merge lp:~jelmer/bzr-builddeb/no-trace-info |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
James Westby | Approve | ||
Robert Collins (community) | Approve | ||
Review via email:
|
Commit message
Description of the change
To post a comment you must log in.
Revision history for this message
![](/+icing/build/overlay/assets/skins/sam/images/close.gif)
Jelmer Vernooij (jelmer) wrote : | # |
Revision history for this message
![](/+icing/build/overlay/assets/skins/sam/images/close.gif)
Robert Collins (lifeless) wrote : | # |
I have a branch doing this and a bit more, too.
review:
Approve
Revision history for this message
![](/+icing/build/overlay/assets/skins/sam/images/close.gif)
James Westby (james-w) wrote : | # |
Looks good. Thanks.
review:
Approve
Preview Diff
[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1 | === modified file 'builder.py' | |||
2 | --- builder.py 2009-07-15 20:48:37 +0000 | |||
3 | +++ builder.py 2009-09-29 14:15:20 +0000 | |||
4 | @@ -23,7 +23,7 @@ | |||
5 | 23 | import subprocess | 23 | import subprocess |
6 | 24 | import os | 24 | import os |
7 | 25 | 25 | ||
9 | 26 | from bzrlib.trace import info | 26 | from bzrlib.trace import note |
10 | 27 | 27 | ||
11 | 28 | from bzrlib.plugins.builddeb.errors import ( | 28 | from bzrlib.plugins.builddeb.errors import ( |
12 | 29 | NoSourceDirError, | 29 | NoSourceDirError, |
13 | @@ -69,10 +69,10 @@ | |||
14 | 69 | os.makedirs(parent_dir) | 69 | os.makedirs(parent_dir) |
15 | 70 | if os.path.exists(self.target_dir): | 70 | if os.path.exists(self.target_dir): |
16 | 71 | if not self.use_existing: | 71 | if not self.use_existing: |
18 | 72 | info("Purging the build dir: %s", self.target_dir) | 72 | note("Purging the build dir: %s", self.target_dir) |
19 | 73 | shutil.rmtree(self.target_dir) | 73 | shutil.rmtree(self.target_dir) |
20 | 74 | else: | 74 | else: |
22 | 75 | info("Not purging build dir as requested: %s", | 75 | note("Not purging build dir as requested: %s", |
23 | 76 | self.target_dir) | 76 | self.target_dir) |
24 | 77 | else: | 77 | else: |
25 | 78 | if self.use_existing: | 78 | if self.use_existing: |
26 | @@ -83,7 +83,7 @@ | |||
27 | 83 | 83 | ||
28 | 84 | def build(self): | 84 | def build(self): |
29 | 85 | """This builds the package using the supplied command.""" | 85 | """This builds the package using the supplied command.""" |
31 | 86 | info("Building the package in %s, using %s", self.target_dir, | 86 | note("Building the package in %s, using %s", self.target_dir, |
32 | 87 | self.builder) | 87 | self.builder) |
33 | 88 | proc = subprocess.Popen(self.builder, shell=True, cwd=self.target_dir, | 88 | proc = subprocess.Popen(self.builder, shell=True, cwd=self.target_dir, |
34 | 89 | preexec_fn=subprocess_setup) | 89 | preexec_fn=subprocess_setup) |
35 | @@ -93,5 +93,5 @@ | |||
36 | 93 | 93 | ||
37 | 94 | def clean(self): | 94 | def clean(self): |
38 | 95 | """This removes the build directory.""" | 95 | """This removes the build directory.""" |
40 | 96 | info("Cleaning build dir: %s", self.target_dir) | 96 | note("Cleaning build dir: %s", self.target_dir) |
41 | 97 | shutil.rmtree(self.target_dir) | 97 | shutil.rmtree(self.target_dir) |
42 | 98 | 98 | ||
43 | === modified file 'cmds.py' | |||
44 | --- cmds.py 2009-09-16 12:47:18 +0000 | |||
45 | +++ cmds.py 2009-09-29 14:15:20 +0000 | |||
46 | @@ -44,7 +44,7 @@ | |||
47 | 44 | from bzrlib.export import export | 44 | from bzrlib.export import export |
48 | 45 | from bzrlib.option import Option | 45 | from bzrlib.option import Option |
49 | 46 | from bzrlib.revisionspec import RevisionSpec | 46 | from bzrlib.revisionspec import RevisionSpec |
51 | 47 | from bzrlib.trace import info, warning | 47 | from bzrlib.trace import note, warning |
52 | 48 | from bzrlib.workingtree import WorkingTree | 48 | from bzrlib.workingtree import WorkingTree |
53 | 49 | 49 | ||
54 | 50 | from bzrlib.plugins.builddeb import ( | 50 | from bzrlib.plugins.builddeb import ( |
55 | @@ -224,7 +224,7 @@ | |||
56 | 224 | 224 | ||
57 | 225 | def _get_build_tree(self, revision, tree, branch): | 225 | def _get_build_tree(self, revision, tree, branch): |
58 | 226 | if revision is None and tree is not None: | 226 | if revision is None and tree is not None: |
60 | 227 | info("Building using working tree") | 227 | note("Building using working tree") |
61 | 228 | working_tree = True | 228 | working_tree = True |
62 | 229 | else: | 229 | else: |
63 | 230 | if revision is None: | 230 | if revision is None: |
64 | @@ -234,7 +234,7 @@ | |||
65 | 234 | else: | 234 | else: |
66 | 235 | raise BzrCommandError('bzr builddeb --revision takes exactly one ' | 235 | raise BzrCommandError('bzr builddeb --revision takes exactly one ' |
67 | 236 | 'revision specifier.') | 236 | 'revision specifier.') |
69 | 237 | info("Building branch from revision %s", revid) | 237 | note("Building branch from revision %s", revid) |
70 | 238 | tree = branch.repository.revision_tree(revid) | 238 | tree = branch.repository.revision_tree(revid) |
71 | 239 | working_tree = False | 239 | working_tree = False |
72 | 240 | return tree, working_tree | 240 | return tree, working_tree |
73 | @@ -243,20 +243,20 @@ | |||
74 | 243 | if not merge: | 243 | if not merge: |
75 | 244 | merge = config.merge | 244 | merge = config.merge |
76 | 245 | if merge: | 245 | if merge: |
78 | 246 | info("Running in merge mode") | 246 | note("Running in merge mode") |
79 | 247 | native = False | 247 | native = False |
80 | 248 | split = False | 248 | split = False |
81 | 249 | else: | 249 | else: |
82 | 250 | if not native: | 250 | if not native: |
83 | 251 | native = config.native | 251 | native = config.native |
84 | 252 | if native: | 252 | if native: |
86 | 253 | info("Running in native mode") | 253 | note("Running in native mode") |
87 | 254 | split = False | 254 | split = False |
88 | 255 | else: | 255 | else: |
89 | 256 | if not split: | 256 | if not split: |
90 | 257 | split = config.split | 257 | split = config.split |
91 | 258 | if split: | 258 | if split: |
93 | 259 | info("Running in split mode") | 259 | note("Running in split mode") |
94 | 260 | return merge, native, split | 260 | return merge, native, split |
95 | 261 | 261 | ||
96 | 262 | def _get_build_command(self, config, builder, quick, build_options): | 262 | def _get_build_command(self, config, builder, quick, build_options): |
97 | @@ -368,7 +368,7 @@ | |||
98 | 368 | try: | 368 | try: |
99 | 369 | config = debuild_config(tree, working_tree, no_user_config) | 369 | config = debuild_config(tree, working_tree, no_user_config) |
100 | 370 | if reuse: | 370 | if reuse: |
102 | 371 | info("Reusing existing build dir") | 371 | note("Reusing existing build dir") |
103 | 372 | dont_purge = True | 372 | dont_purge = True |
104 | 373 | use_existing = True | 373 | use_existing = True |
105 | 374 | merge, native, split = self._build_type(config, merge, native, split) | 374 | merge, native, split = self._build_type(config, merge, native, split) |
106 | @@ -533,11 +533,11 @@ | |||
107 | 533 | if distribution is None: | 533 | if distribution is None: |
108 | 534 | distribution = find_last_distribution(changelog) | 534 | distribution = find_last_distribution(changelog) |
109 | 535 | if distribution is not None: | 535 | if distribution is not None: |
111 | 536 | info("Using distribution %s" % distribution) | 536 | note("Using distribution %s" % distribution) |
112 | 537 | except MissingChangelogError: | 537 | except MissingChangelogError: |
113 | 538 | current_version = None | 538 | current_version = None |
114 | 539 | if distribution is None: | 539 | if distribution is None: |
116 | 540 | info("No distribution specified, and no changelog, " | 540 | note("No distribution specified, and no changelog, " |
117 | 541 | "assuming 'debian'") | 541 | "assuming 'debian'") |
118 | 542 | distribution = "debian" | 542 | distribution = "debian" |
119 | 543 | 543 | ||
120 | @@ -581,7 +581,7 @@ | |||
121 | 581 | version = upstream_branch_version(upstream_branch, | 581 | version = upstream_branch_version(upstream_branch, |
122 | 582 | upstream_revision, package, | 582 | upstream_revision, package, |
123 | 583 | current_version.upstream_version) | 583 | current_version.upstream_version) |
125 | 584 | info("Using version string %s for upstream branch." % (version)) | 584 | note("Using version string %s for upstream branch." % (version)) |
126 | 585 | else: | 585 | else: |
127 | 586 | raise BzrCommandError("You must specify the " | 586 | raise BzrCommandError("You must specify the " |
128 | 587 | "version number using --version.") | 587 | "version number using --version.") |
129 | @@ -620,11 +620,11 @@ | |||
130 | 620 | package) | 620 | package) |
131 | 621 | finally: | 621 | finally: |
132 | 622 | tree.unlock() | 622 | tree.unlock() |
134 | 623 | info("The new upstream version has been imported.") | 623 | note("The new upstream version has been imported.") |
135 | 624 | if conflicts: | 624 | if conflicts: |
137 | 625 | info("You should now resolve the conflicts, review the changes, and then commit.") | 625 | note("You should now resolve the conflicts, review the changes, and then commit.") |
138 | 626 | else: | 626 | else: |
140 | 627 | info("You should now review the changes and then commit.") | 627 | note("You should now review the changes and then commit.") |
141 | 628 | 628 | ||
142 | 629 | 629 | ||
143 | 630 | class cmd_import_dsc(Command): | 630 | class cmd_import_dsc(Command): |
144 | @@ -808,16 +808,16 @@ | |||
145 | 808 | builder.prepare() | 808 | builder.prepare() |
146 | 809 | run_hook(t, 'pre-export', config) | 809 | run_hook(t, 'pre-export', config) |
147 | 810 | builder.export() | 810 | builder.export() |
149 | 811 | info('Running "%s" in the exported directory.' % (command)) | 811 | note('Running "%s" in the exported directory.' % (command)) |
150 | 812 | if give_instruction: | 812 | if give_instruction: |
152 | 813 | info('If you want to cancel your changes then exit with a non-zero ' | 813 | note('If you want to cancel your changes then exit with a non-zero ' |
153 | 814 | 'exit code, e.g. run "exit 1".') | 814 | 'exit code, e.g. run "exit 1".') |
154 | 815 | try: | 815 | try: |
155 | 816 | builder.build() | 816 | builder.build() |
156 | 817 | except BuildFailedError: | 817 | except BuildFailedError: |
157 | 818 | raise BzrCommandError('Not updating the working tree as the ' | 818 | raise BzrCommandError('Not updating the working tree as the ' |
158 | 819 | 'command failed.') | 819 | 'command failed.') |
160 | 820 | info("Copying debian/ back") | 820 | note("Copying debian/ back") |
161 | 821 | if larstiq: | 821 | if larstiq: |
162 | 822 | destination = '' | 822 | destination = '' |
163 | 823 | else: | 823 | else: |
164 | @@ -832,7 +832,7 @@ | |||
165 | 832 | if proc.returncode != 0: | 832 | if proc.returncode != 0: |
166 | 833 | raise BzrCommandError('Copying back debian/ failed') | 833 | raise BzrCommandError('Copying back debian/ failed') |
167 | 834 | builder.clean() | 834 | builder.clean() |
169 | 835 | info('If any files were added or removed you should run "bzr add" or ' | 835 | note('If any files were added or removed you should run "bzr add" or ' |
170 | 836 | '"bzr rm" as appropriate.') | 836 | '"bzr rm" as appropriate.') |
171 | 837 | 837 | ||
172 | 838 | 838 | ||
173 | @@ -913,10 +913,10 @@ | |||
174 | 913 | # Merge source packaging branch in to the target packaging branch. | 913 | # Merge source packaging branch in to the target packaging branch. |
175 | 914 | conflicts = tree.merge_from_branch(source_branch) | 914 | conflicts = tree.merge_from_branch(source_branch) |
176 | 915 | if conflicts > 0: | 915 | if conflicts > 0: |
178 | 916 | info('The merge resulted in %s conflicts. Please resolve these ' | 916 | note('The merge resulted in %s conflicts. Please resolve these ' |
179 | 917 | 'and commit the changes with "bzr commit".' % conflicts) | 917 | 'and commit the changes with "bzr commit".' % conflicts) |
180 | 918 | else: | 918 | else: |
182 | 919 | info('The merge resulted in no conflicts. You may commit the ' | 919 | note('The merge resulted in no conflicts. You may commit the ' |
183 | 920 | 'changes by running "bzr commit".') | 920 | 'changes by running "bzr commit".') |
184 | 921 | 921 | ||
185 | 922 | 922 | ||
186 | 923 | 923 | ||
187 | === modified file 'directory.py' | |||
188 | --- directory.py 2009-04-16 10:42:12 +0000 | |||
189 | +++ directory.py 2009-09-29 14:15:20 +0000 | |||
190 | @@ -19,7 +19,7 @@ | |||
191 | 19 | # | 19 | # |
192 | 20 | 20 | ||
193 | 21 | from bzrlib import errors | 21 | from bzrlib import errors |
195 | 22 | from bzrlib.trace import info | 22 | from bzrlib.trace import note |
196 | 23 | 23 | ||
197 | 24 | import apt_pkg | 24 | import apt_pkg |
198 | 25 | 25 | ||
199 | @@ -61,7 +61,7 @@ | |||
200 | 61 | raise errors.InvalidURL(path=url, | 61 | raise errors.InvalidURL(path=url, |
201 | 62 | extra='version %s not found' % version) | 62 | extra='version %s not found' % version) |
202 | 63 | 63 | ||
204 | 64 | info("Retrieving Vcs locating from %s Debian version %s", name, version) | 64 | note("Retrieving Vcs locating from %s Debian version %s", name, version) |
205 | 65 | 65 | ||
206 | 66 | if "Bzr" in urls[version]: | 66 | if "Bzr" in urls[version]: |
207 | 67 | return urls[version]["Bzr"] | 67 | return urls[version]["Bzr"] |
208 | @@ -70,7 +70,7 @@ | |||
209 | 70 | try: | 70 | try: |
210 | 71 | import bzrlib.plugins.svn | 71 | import bzrlib.plugins.svn |
211 | 72 | except ImportError: | 72 | except ImportError: |
213 | 73 | info("This package uses subversion. If you would like to " | 73 | note("This package uses subversion. If you would like to " |
214 | 74 | "access it with bzr then please install bzr-svn " | 74 | "access it with bzr then please install bzr-svn " |
215 | 75 | "and re-run the command.") | 75 | "and re-run the command.") |
216 | 76 | else: | 76 | else: |
217 | @@ -80,7 +80,7 @@ | |||
218 | 80 | try: | 80 | try: |
219 | 81 | import bzrlib.plugins.git | 81 | import bzrlib.plugins.git |
220 | 82 | except ImportError: | 82 | except ImportError: |
222 | 83 | info("This package uses git. If you would like to " | 83 | note("This package uses git. If you would like to " |
223 | 84 | "access it with bzr then please install bzr-git " | 84 | "access it with bzr then please install bzr-git " |
224 | 85 | "and re-run the command.") | 85 | "and re-run the command.") |
225 | 86 | else: | 86 | else: |
226 | @@ -90,7 +90,7 @@ | |||
227 | 90 | try: | 90 | try: |
228 | 91 | import bzrlib.plugins.hg | 91 | import bzrlib.plugins.hg |
229 | 92 | except ImportError: | 92 | except ImportError: |
231 | 93 | info("This package uses hg. If you would like to " | 93 | note("This package uses hg. If you would like to " |
232 | 94 | "access it with bzr then please install bzr-hg" | 94 | "access it with bzr then please install bzr-hg" |
233 | 95 | "and re-run the command.") | 95 | "and re-run the command.") |
234 | 96 | else: | 96 | else: |
235 | 97 | 97 | ||
236 | === modified file 'hooks.py' | |||
237 | --- hooks.py 2008-05-18 00:04:21 +0000 | |||
238 | +++ hooks.py 2009-09-29 14:15:20 +0000 | |||
239 | @@ -20,7 +20,7 @@ | |||
240 | 20 | 20 | ||
241 | 21 | import subprocess | 21 | import subprocess |
242 | 22 | 22 | ||
244 | 23 | from bzrlib.trace import info | 23 | from bzrlib.trace import note |
245 | 24 | 24 | ||
246 | 25 | from bzrlib.plugins.builddeb.errors import HookFailedError | 25 | from bzrlib.plugins.builddeb.errors import HookFailedError |
247 | 26 | 26 | ||
248 | @@ -29,7 +29,7 @@ | |||
249 | 29 | hook = config.get_hook(hook_name) | 29 | hook = config.get_hook(hook_name) |
250 | 30 | if hook is None: | 30 | if hook is None: |
251 | 31 | return | 31 | return |
253 | 32 | info("Running %s as %s hook" % (hook, hook_name)) | 32 | note("Running %s as %s hook" % (hook, hook_name)) |
254 | 33 | proc = subprocess.Popen(hook, shell=True, | 33 | proc = subprocess.Popen(hook, shell=True, |
255 | 34 | cwd=tree.abspath(wd)) | 34 | cwd=tree.abspath(wd)) |
256 | 35 | proc.wait() | 35 | proc.wait() |
257 | 36 | 36 | ||
258 | === modified file 'import_dsc.py' | |||
259 | --- import_dsc.py 2009-09-16 14:52:14 +0000 | |||
260 | +++ import_dsc.py 2009-09-29 14:15:20 +0000 | |||
261 | @@ -59,7 +59,7 @@ | |||
262 | 59 | from bzrlib.osutils import file_iterator, isdir, basename, splitpath | 59 | from bzrlib.osutils import file_iterator, isdir, basename, splitpath |
263 | 60 | from bzrlib.revisionspec import RevisionSpec | 60 | from bzrlib.revisionspec import RevisionSpec |
264 | 61 | from bzrlib.revision import NULL_REVISION | 61 | from bzrlib.revision import NULL_REVISION |
266 | 62 | from bzrlib.trace import warning, info, mutter | 62 | from bzrlib.trace import warning, mutter, note |
267 | 63 | from bzrlib.transform import TreeTransform, cook_conflicts, resolve_conflicts | 63 | from bzrlib.transform import TreeTransform, cook_conflicts, resolve_conflicts |
268 | 64 | from bzrlib.transport import ( | 64 | from bzrlib.transport import ( |
269 | 65 | get_transport, | 65 | get_transport, |
270 | @@ -1728,7 +1728,7 @@ | |||
271 | 1728 | finally: | 1728 | finally: |
272 | 1729 | tree.unlock() | 1729 | tree.unlock() |
273 | 1730 | command = ["/usr/bin/pristine-tar", "gendelta", tarball_path, "-"] | 1730 | command = ["/usr/bin/pristine-tar", "gendelta", tarball_path, "-"] |
275 | 1731 | info(" ".join(command)) | 1731 | note(" ".join(command)) |
276 | 1732 | proc = Popen(command, stdout=PIPE, cwd=dest) | 1732 | proc = Popen(command, stdout=PIPE, cwd=dest) |
277 | 1733 | (stdout, stderr) = proc.communicate() | 1733 | (stdout, stderr) = proc.communicate() |
278 | 1734 | if proc.returncode != 0: | 1734 | if proc.returncode != 0: |
279 | 1735 | 1735 | ||
280 | === modified file 'upstream.py' | |||
281 | --- upstream.py 2009-09-14 15:38:18 +0000 | |||
282 | +++ upstream.py 2009-09-29 14:15:20 +0000 | |||
283 | @@ -28,7 +28,7 @@ | |||
284 | 28 | 28 | ||
285 | 29 | from bzrlib.export import export | 29 | from bzrlib.export import export |
286 | 30 | from bzrlib.revisionspec import RevisionSpec | 30 | from bzrlib.revisionspec import RevisionSpec |
288 | 31 | from bzrlib.trace import info | 31 | from bzrlib.trace import note |
289 | 32 | 32 | ||
290 | 33 | from bzrlib.plugins.builddeb.errors import ( | 33 | from bzrlib.plugins.builddeb.errors import ( |
291 | 34 | MissingUpstreamTarball, | 34 | MissingUpstreamTarball, |
292 | @@ -83,7 +83,7 @@ | |||
293 | 83 | revid = db.revid_of_upstream_version_from_branch(version) | 83 | revid = db.revid_of_upstream_version_from_branch(version) |
294 | 84 | if not db.has_pristine_tar_delta(revid): | 84 | if not db.has_pristine_tar_delta(revid): |
295 | 85 | raise PackageVersionNotPresent(package, version, self) | 85 | raise PackageVersionNotPresent(package, version, self) |
297 | 86 | info("Using pristine-tar to reconstruct the needed tarball.") | 86 | note("Using pristine-tar to reconstruct the needed tarball.") |
298 | 87 | try: | 87 | try: |
299 | 88 | db.reconstruct_pristine_tar(revid, package, version, target_filename) | 88 | db.reconstruct_pristine_tar(revid, package, version, target_filename) |
300 | 89 | except PristineTarError: | 89 | except PristineTarError: |
301 | @@ -109,14 +109,14 @@ | |||
302 | 109 | raise PackageVersionNotPresent(package, upstream_version, self) | 109 | raise PackageVersionNotPresent(package, upstream_version, self) |
303 | 110 | 110 | ||
304 | 111 | sources.Restart() | 111 | sources.Restart() |
306 | 112 | info("Using apt to look for the upstream tarball.") | 112 | note("Using apt to look for the upstream tarball.") |
307 | 113 | while sources.Lookup(package): | 113 | while sources.Lookup(package): |
308 | 114 | if upstream_version \ | 114 | if upstream_version \ |
309 | 115 | == Version(sources.Version).upstream_version: | 115 | == Version(sources.Version).upstream_version: |
310 | 116 | if self._run_apt_source(package, sources.Version, target_dir): | 116 | if self._run_apt_source(package, sources.Version, target_dir): |
311 | 117 | return | 117 | return |
312 | 118 | break | 118 | break |
314 | 119 | info("apt could not find the needed tarball.") | 119 | note("apt could not find the needed tarball.") |
315 | 120 | raise PackageVersionNotPresent(package, upstream_version, self) | 120 | raise PackageVersionNotPresent(package, upstream_version, self) |
316 | 121 | 121 | ||
317 | 122 | def _get_command(self, package, version_str): | 122 | def _get_command(self, package, version_str): |
318 | @@ -157,7 +157,7 @@ | |||
319 | 157 | self.upstream_branch.lock_read() | 157 | self.upstream_branch.lock_read() |
320 | 158 | try: | 158 | try: |
321 | 159 | revid = self._get_revision_id(version) | 159 | revid = self._get_revision_id(version) |
323 | 160 | info("Exporting upstream branch revision %s to create the tarball", | 160 | note("Exporting upstream branch revision %s to create the tarball", |
324 | 161 | revid) | 161 | revid) |
325 | 162 | target_filename = self._tarball_path(package, version, target_dir) | 162 | target_filename = self._tarball_path(package, version, target_dir) |
326 | 163 | tarball_base = "%s-%s" % (package, version) | 163 | tarball_base = "%s-%s" % (package, version) |
327 | @@ -176,16 +176,16 @@ | |||
328 | 176 | 176 | ||
329 | 177 | def _get_orig_source(self, source_dir, desired_tarball_name, | 177 | def _get_orig_source(self, source_dir, desired_tarball_name, |
330 | 178 | target_dir): | 178 | target_dir): |
332 | 179 | info("Trying to use get-orig-source to retrieve needed tarball.") | 179 | note("Trying to use get-orig-source to retrieve needed tarball.") |
333 | 180 | command = ["/usr/bin/make", "-f", "debian/rules", "get-orig-source"] | 180 | command = ["/usr/bin/make", "-f", "debian/rules", "get-orig-source"] |
334 | 181 | proc = subprocess.Popen(command, cwd=source_dir) | 181 | proc = subprocess.Popen(command, cwd=source_dir) |
335 | 182 | ret = proc.wait() | 182 | ret = proc.wait() |
336 | 183 | if ret != 0: | 183 | if ret != 0: |
338 | 184 | info("Trying to run get-orig-source rule failed") | 184 | note("Trying to run get-orig-source rule failed") |
339 | 185 | return False | 185 | return False |
340 | 186 | fetched_tarball = os.path.join(source_dir, desired_tarball_name) | 186 | fetched_tarball = os.path.join(source_dir, desired_tarball_name) |
341 | 187 | if not os.path.exists(fetched_tarball): | 187 | if not os.path.exists(fetched_tarball): |
343 | 188 | info("get-orig-source did not create %s", desired_tarball_name) | 188 | note("get-orig-source did not create %s", desired_tarball_name) |
344 | 189 | return False | 189 | return False |
345 | 190 | repack_tarball(fetched_tarball, desired_tarball_name, | 190 | repack_tarball(fetched_tarball, desired_tarball_name, |
346 | 191 | target_dir=target_dir) | 191 | target_dir=target_dir) |
347 | @@ -213,7 +213,7 @@ | |||
348 | 213 | return | 213 | return |
349 | 214 | finally: | 214 | finally: |
350 | 215 | shutil.rmtree(tmpdir) | 215 | shutil.rmtree(tmpdir) |
352 | 216 | info("No debian/rules file to try and use for a get-orig-source rule") | 216 | note("No debian/rules file to try and use for a get-orig-source rule") |
353 | 217 | raise PackageVersionNotPresent(package, version, self) | 217 | raise PackageVersionNotPresent(package, version, self) |
354 | 218 | 218 | ||
355 | 219 | 219 | ||
356 | @@ -225,14 +225,14 @@ | |||
357 | 225 | self.larstiq = larstiq | 225 | self.larstiq = larstiq |
358 | 226 | 226 | ||
359 | 227 | def _uscan(self, package, upstream_version, watch_file, target_dir): | 227 | def _uscan(self, package, upstream_version, watch_file, target_dir): |
361 | 228 | info("Using uscan to look for the upstream tarball.") | 228 | note("Using uscan to look for the upstream tarball.") |
362 | 229 | r = os.system("uscan --upstream-version %s --force-download --rename " | 229 | r = os.system("uscan --upstream-version %s --force-download --rename " |
363 | 230 | "--package %s --watchfile %s --check-dirname-level 0 " | 230 | "--package %s --watchfile %s --check-dirname-level 0 " |
364 | 231 | "--download --repack --destdir %s --download-version %s" % | 231 | "--download --repack --destdir %s --download-version %s" % |
365 | 232 | (upstream_version, package, watch_file, target_dir, | 232 | (upstream_version, package, watch_file, target_dir, |
366 | 233 | upstream_version)) | 233 | upstream_version)) |
367 | 234 | if r != 0: | 234 | if r != 0: |
369 | 235 | info("uscan could not find the needed tarball.") | 235 | note("uscan could not find the needed tarball.") |
370 | 236 | return False | 236 | return False |
371 | 237 | return True | 237 | return True |
372 | 238 | 238 | ||
373 | @@ -243,7 +243,7 @@ | |||
374 | 243 | watchfile = 'debian/watch' | 243 | watchfile = 'debian/watch' |
375 | 244 | watch_id = self.tree.path2id(watchfile) | 244 | watch_id = self.tree.path2id(watchfile) |
376 | 245 | if watch_id is None: | 245 | if watch_id is None: |
378 | 246 | info("No watch file to use to retrieve upstream tarball.") | 246 | note("No watch file to use to retrieve upstream tarball.") |
379 | 247 | return None | 247 | return None |
380 | 248 | (tmp, tempfilename) = tempfile.mkstemp() | 248 | (tmp, tempfilename) = tempfile.mkstemp() |
381 | 249 | try: | 249 | try: |
382 | @@ -287,7 +287,7 @@ | |||
383 | 287 | shutil.rmtree(tmpdir) | 287 | shutil.rmtree(tmpdir) |
384 | 288 | 288 | ||
385 | 289 | def get_specific_version(self, package, version, target_dir): | 289 | def get_specific_version(self, package, version, target_dir): |
387 | 290 | info("Using the current branch without the 'debian' directory " | 290 | note("Using the current branch without the 'debian' directory " |
388 | 291 | "to create the tarball") | 291 | "to create the tarball") |
389 | 292 | self._split(package, version, | 292 | self._split(package, version, |
390 | 293 | self._tarball_path(package, version, target_dir)) | 293 | self._tarball_path(package, version, target_dir)) |
391 | @@ -387,9 +387,9 @@ | |||
392 | 387 | :param target_dir: The directory to place the tarball in. | 387 | :param target_dir: The directory to place the tarball in. |
393 | 388 | :return: The path to the tarball. | 388 | :return: The path to the tarball. |
394 | 389 | """ | 389 | """ |
396 | 390 | info("Looking for a way to retrieve the upstream tarball") | 390 | note("Looking for a way to retrieve the upstream tarball") |
397 | 391 | if self.already_exists_in_target(target_dir): | 391 | if self.already_exists_in_target(target_dir): |
399 | 392 | info("Upstream tarball already exists in build directory, " | 392 | note("Upstream tarball already exists in build directory, " |
400 | 393 | "using that") | 393 | "using that") |
401 | 394 | return os.path.join(target_dir, self._tarball_name()) | 394 | return os.path.join(target_dir, self._tarball_name()) |
402 | 395 | if not self.already_exists_in_store(): | 395 | if not self.already_exists_in_store(): |
403 | @@ -401,7 +401,7 @@ | |||
404 | 401 | except PackageVersionNotPresent: | 401 | except PackageVersionNotPresent: |
405 | 402 | raise MissingUpstreamTarball(self._tarball_name()) | 402 | raise MissingUpstreamTarball(self._tarball_name()) |
406 | 403 | else: | 403 | else: |
408 | 404 | info("Using the upstream tarball that is present in " | 404 | note("Using the upstream tarball that is present in " |
409 | 405 | "%s" % self.store_dir) | 405 | "%s" % self.store_dir) |
410 | 406 | assert self.provide_from_store_dir(target_dir) | 406 | assert self.provide_from_store_dir(target_dir) |
411 | 407 | return os.path.join(target_dir, self._tarball_name()) | 407 | return os.path.join(target_dir, self._tarball_name()) |
This removes the calls to bzrlib. trace.info( ), which is deprecated in bzr 2.1.