Skip to content

feat(mk): add makefiles to allow building deps outside docker#61

Draft
alexandermerritt wants to merge 5 commits into
mainfrom
alexm/dev-build
Draft

feat(mk): add makefiles to allow building deps outside docker#61
alexandermerritt wants to merge 5 commits into
mainfrom
alexm/dev-build

Conversation

@alexandermerritt
Copy link
Copy Markdown
Contributor

@alexandermerritt alexandermerritt commented Feb 26, 2026

Related issue: #2235

Comment thread common.mk

$(XEN_SRC):
git clone -b $(XEN_BRANCH) $(XEN_URL) $@

Copy link
Copy Markdown
Contributor

@bleggett bleggett Feb 27, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm fine doing all this in make but we should delete the equivalent steps from the Dockerfiles and just invoke these make targets directly from the respective Dockerfiles in this PR, otherwise we risk adding two parallel sets of setup/install/clone steps - and variables - that inevitably will drift, since CI only exercises the Dockerfiles as an entrypoint.

Comment thread Makefile.oxenstored
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ditto - we should go ahead and make remove the duplicated steps from the Dockerfile and use the corresponding makefiles in the respective Dockerfiles.

Also, I think we should use the full component name in the makefile name -> Makefile.oxenstored et al. Not only is this more obvious/discoverable if you're just looking at the repo, it maintains a 1-1 mapping between e.g. Dockerfile.oxenstored and Makefile.oxenstored in the tree, which is also more obvious/discoverable.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use the full component name in the makefile name

Agreed, will update.

Comment thread Makefile.qemu-xen
@@ -0,0 +1,122 @@
.PHONY: all
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ditto

  • Makefile.qemu-xen and dedupe the Dockerfile.

Comment thread common.mk
git clone -b $(XEN_BRANCH) $(XEN_URL) $@

.PHONY: install-deps
install-deps:
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

install-deps as written here won't work in non-apt envs, which includes the dockerfiles themselves and any non-Debian local distro anyone tries to run this against.

So I would suggest to

  • Define the packageset/install cmd in the Dockerfile (where the env is fixed), and have make targets assume all ambient deps are already present.
  • Remove this and document it (as you do below) instead of encoding it as a make target, for direct, non-Docker builds - people will have to make sure the deps are present before building locally outside of Docker.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense, I agree. This was just a hack for myself.

@alexandermerritt
Copy link
Copy Markdown
Contributor Author

I was planning to make edits to the Docker scripts in a separate PR, is that alright? I'll update the Makefile names and remove the install-deps target.

Signed-off-by: Alexander Merritt <alexander@edera.dev>
Make it easier to build our software locally without added environment
constraints, such as Docker and OCI registries.

Included readme for documentation.

Signed-off-by: Alexander Merritt <alexander@edera.dev>
@alexandermerritt
Copy link
Copy Markdown
Contributor Author

I was planning to make edits to the Docker scripts in a separate PR, is that alright? I'll update the Makefile names and remove the install-deps target.

Actually maybe it makes sense to do that all in this PR... I'll give it a shot.

@alexandermerritt alexandermerritt changed the title chore(mk): add makefiles to allow building deps outside docker DRAFT: chore(mk): add makefiles to allow building deps outside docker Feb 28, 2026
@alexandermerritt alexandermerritt marked this pull request as draft February 28, 2026 17:30
@alexandermerritt alexandermerritt changed the title DRAFT: chore(mk): add makefiles to allow building deps outside docker chore(mk): add makefiles to allow building deps outside docker Feb 28, 2026
@alexandermerritt alexandermerritt changed the title chore(mk): add makefiles to allow building deps outside docker feat(mk): add makefiles to allow building deps outside docker Feb 28, 2026
@bleggett
Copy link
Copy Markdown
Contributor

bleggett commented Mar 2, 2026

I was planning to make edits to the Docker scripts in a separate PR, is that alright? I'll update the Makefile names and remove the install-deps target.

Actually maybe it makes sense to do that all in this PR... I'll give it a shot.

Thanks - dealer's choice - if you do create a separate PR, please do try and crosslink it with this one. You can also have multiple PRs in flight at the same time and we can just merge them in the desired order, up to you.

clupuishere and others added 3 commits March 23, 2026 08:53
... to keep it light.

Signed-off-by: Costin Lupu <costin@edera.dev>
We have a singular rolling branch for Xen in our own repo.
Any new patches to it should be committed to that, rather than
maintained here.

Similarly for QEMU, merge the 4.21 patch into our qemu-xen repo for
maintenance there.

This commit must coincide with an update to the qemu-xen repo we
maintain, as we are removing the patch here.

Signed-off-by: Alexander Merritt <alexander@edera.dev>
Signed-off-by: Alexander Merritt <alexander@edera.dev>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants