mirror of
https://git.launchpad.net/ubuntu-dev-tools
synced 2025-03-13 08:01:09 +00:00
builder.py: Pass ARCH to pbuilder too.
This commit is contained in:
parent
3f3018aef2
commit
c8e71cacee
@ -47,8 +47,8 @@ defaults to \fB~ppa1\fR, otherwise the default is blank.
|
|||||||
.B \-b\fR, \fB\-\-build
|
.B \-b\fR, \fB\-\-build
|
||||||
Build the package with the specified builder before uploading. Note
|
Build the package with the specified builder before uploading. Note
|
||||||
for \fBpbuilder\fR(8) users: This assumes the common configuration,
|
for \fBpbuilder\fR(8) users: This assumes the common configuration,
|
||||||
where the \fBDIST\fR environment is read by \fBpbuilderrc\fR(5) to
|
where the \fBARCH\fR and \fBDIST\fR environment is read by \fBpbuilderrc\fR(5)
|
||||||
select the correct base image.
|
to select the correct base image.
|
||||||
.TP
|
.TP
|
||||||
.B \-B \fIBUILDER\fR, \fB\-\-builder\fR=\fIBUILDER
|
.B \-B \fIBUILDER\fR, \fB\-\-builder\fR=\fIBUILDER
|
||||||
Use the specified builder to build the package. Supported are
|
Use the specified builder to build the package. Supported are
|
||||||
|
@ -55,8 +55,8 @@ The output of the build tool will be placed in \fIworkdir\fR/\fBbuildresult/\fR.
|
|||||||
.TP
|
.TP
|
||||||
.BR \-b ", " \-\-build
|
.BR \-b ", " \-\-build
|
||||||
Build the package with the specified builder. Note for \fBpbuilder\fR(8) users:
|
Build the package with the specified builder. Note for \fBpbuilder\fR(8) users:
|
||||||
This assumes the common configuration, where the \fBDIST\fR environment is read
|
This assumes the common configuration, where the \fBARCH\fR and \fBDIST\fR
|
||||||
by \fBpbuilderrc\fR(5) to select the correct base image.
|
environment is read by \fBpbuilderrc\fR(5) to select the correct base image.
|
||||||
.TP
|
.TP
|
||||||
.B \-B \fIBUILDER\fR, \fB\-\-builder\fR=\fIBUILDER
|
.B \-B \fIBUILDER\fR, \fB\-\-builder\fR=\fIBUILDER
|
||||||
Use the specify builder to build the package.
|
Use the specify builder to build the package.
|
||||||
|
@ -60,17 +60,18 @@ class Pbuilder(Builder):
|
|||||||
|
|
||||||
def build(self, dsc_file, dist, result_directory):
|
def build(self, dsc_file, dist, result_directory):
|
||||||
_build_preparation(result_directory)
|
_build_preparation(result_directory)
|
||||||
# TODO: Do not rely on a specific pbuilder configuration.
|
cmd = ["sudo", "-E", "ARCH=" + self.architecture, "DIST=" + dist,
|
||||||
cmd = ["sudo", "-E", "DIST=" + dist, "pbuilder", "--build",
|
"pbuilder", "--build",
|
||||||
"--distribution", dist, "--architecture", self.architecture,
|
"--architecture", self.architecture, "--distribution", dist,
|
||||||
"--buildresult", result_directory, dsc_file]
|
"--buildresult", result_directory, dsc_file]
|
||||||
Logger.command(cmd)
|
Logger.command(cmd)
|
||||||
returncode = subprocess.call(cmd)
|
returncode = subprocess.call(cmd)
|
||||||
return self._build_failure(returncode, dsc_file)
|
return self._build_failure(returncode, dsc_file)
|
||||||
|
|
||||||
def update(self, dist):
|
def update(self, dist):
|
||||||
cmd = ["sudo", "-E", "DIST=" + dist, "pbuilder", "--update",
|
cmd = ["sudo", "-E", "ARCH=" + self.architecture, "DIST=" + dist,
|
||||||
"--distribution", dist, "--architecture", self.architecture]
|
"pbuilder", "--update",
|
||||||
|
"--architecture", self.architecture, "--distribution", dist]
|
||||||
Logger.command(cmd)
|
Logger.command(cmd)
|
||||||
returncode = subprocess.call(cmd)
|
returncode = subprocess.call(cmd)
|
||||||
return self._update_failure(returncode, dist)
|
return self._update_failure(returncode, dist)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user