← Back to team overview

launchpad-reviewers team mailing list archive

[Merge] ~cjwatson/launchpad:fix-build-tarball-assets into launchpad:master

 

Colin Watson has proposed merging ~cjwatson/launchpad:fix-build-tarball-assets into launchpad:master.

Commit message:
Move asset build to be local to build-tarball

Requested reviews:
  Launchpad code reviewers (launchpad-reviewers)

For more details, see:
https://code.launchpad.net/~cjwatson/launchpad/+git/launchpad/+merge/441863

The `build_wheels_only` target in the `Makefile` is used by both legacy deployments (via a complex chain of systems that include a call to `make build_wheels`) and Juju deployments (via a Jenkins job that calls `make publish-tarball`).  We need `make publish-tarball` to build assets in order to support a future charm, but `make build_wheels` can't do so because the legacy build machine doesn't have the right dependencies installed - and we probably don't want to re-engineer those deployments too heavily anyway.

Moving this to the `build-tarball` script and reverting the `Makefile` changes lets us make things work the way they need to for Juju deployments, while fixing legacy deployments.
-- 
Your team Launchpad code reviewers is requested to review the proposed merge of ~cjwatson/launchpad:fix-build-tarball-assets into launchpad:master.
diff --git a/Makefile b/Makefile
index a6b86ab..ebacd51 100644
--- a/Makefile
+++ b/Makefile
@@ -278,7 +278,7 @@ requirements/combined.txt: \
 # dependencies without also building a useless wheel of Launchpad itself;
 # fortunately that doesn't take too long, and we just remove it afterwards.
 .PHONY: build_wheels_only
-build_wheels_only: build
+build_wheels_only: $(PIP_BIN) requirements/combined.txt
 	$(RM) -r wheelhouse wheels
 	$(SHHH) $(PIP) wheel -w wheels -r requirements/setup.txt
 	$(SHHH) $(PIP) wheel \
diff --git a/utilities/build-tarball b/utilities/build-tarball
index 0d4cb88..fcbdc19 100755
--- a/utilities/build-tarball
+++ b/utilities/build-tarball
@@ -16,7 +16,7 @@ output_dir="$1"
 # the Makefile and also has to call out to the Makefile, but this is
 # difficult to disentangle until we refactor our build system to use
 # something higher-level than pip.
-make build_wheels_only
+make build build_wheels_only
 
 # Ensure that we have an updated idea of this tree's version.
 scripts/update-version-info.sh