Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Podman/Buildah: Add uCPP package via new build-arg #36

Merged
merged 2 commits into from
Jun 20, 2024

Conversation

cevich
Copy link
Member

@cevich cevich commented Jun 17, 2024

Fixes #35

Since podman supports use of a #include directive in Containerfile
it's prudent to include the tooling necessary to fully make use of this
feature. Add a symlink from cpp -> ucpp as there isn't one by
default.

Also, since downstream users of the podman image may want a
way to more easily customize the package list, de-duplicate
the specification via a new build-arg.

@cevich
Copy link
Member Author

cevich commented Jun 17, 2024

@iluminae @vrothberg @Luap99 @rhatdan PTAL and LMK if this is good enough. Esp. if the cpp -> ucpp symlink is desirable. I did some manual testing and running the (symlinked) cpp -E foo.in seems to resolve #include directives properly.

@cevich cevich requested review from Luap99 June 17, 2024 20:30
@cevich cevich marked this pull request as ready for review June 17, 2024 20:30
vrothberg
vrothberg previously approved these changes Jun 18, 2024
Copy link
Member

@vrothberg vrothberg left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Member

@Luap99 Luap99 left a comment

Choose a reason for hiding this comment

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

LGTM, I have not tested this though.

@cevich
Copy link
Member Author

cevich commented Jun 18, 2024

If it helps, I pushed a locally built test-image as quay.io/cevich/podman:latest

Since podman supports use of a `#include` directive in `Containerfile`
it's prudent to include the tooling necessary to fully make use of this
feature.  Add a symlink from `cpp` -> `ucpp` as there isn't one by
default.

Also, since downstream users of the podman image may want a
way to more easily customize the package list, de-duplicate
the specification via a new build-arg.

Signed-off-by: Chris Evich <cevich@redhat.com>
@cevich cevich changed the title Podman: Add uCPP package via new build-arg Podman/Buildah: Add uCPP package via new build-arg Jun 20, 2024
It's unlikely that a full-blown C pre-pocessor is required.  My
understanding is this package was added in order to support the
`Containerfile.in` `#include` feature.  This can easily be accomplished
with `ucpp` at a greatly reduced overall image size.  Realize this
effect while de-duplicating the package list via a build-arg.

Signed-off-by: Chris Evich <cevich@redhat.com>
@cevich
Copy link
Member Author

cevich commented Jun 20, 2024

Force-push: Switch buildah image from cpp -> ucpp to reduce size (by ~60mb) and make Containerfile resemble podman's more closely. This will make future de-duplication easier.

@cevich
Copy link
Member Author

cevich commented Jun 20, 2024

Manually tested new podman and buildah images.

@cevich cevich merged commit 147ee0b into containers:main Jun 20, 2024
15 checks passed
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.

Published images do not include cpp
3 participants