Makefile: Don't read COMMIT, BUILDTAGS, EXTRA_BUILDTAGS from env vars#4380
Conversation
|
🙈 needs a rebase |
We recently switched VERSION to be read from env vars (opencontainers#4270). This broke several projects, as they were building runc and using a `VERSION` env var for, e.g. the containerd version. When fixing that in opencontainers#4370, we discussed to consider doing the same for these variables too (opencontainers#4370 (review)). Let's stop reading them from env vars, as it is very easy to do it by mistake (e.g. compile runc and define a COMMIT env var, not to override the commit shown in `runc --version`) and users that want can still override them if they want to. For example, with: make EXTRA_BUILDTAGS=runc_nodmz Signed-off-by: Rodrigo Campos <rodrigoca@microsoft.com>
|
Rebased now :) |
|
Wait... this now breaks builds again. |
|
There is no way to set a COMMIT except by carrying a patch to overwrite this. Keep in mind that most of the time packagers do not have a |
|
Doesn't |
|
Oh yes, you are right. I always forget that make args can set those vars even without |
No patch is needed. I am building internally using |
|
Yeah, it's easy to confuse order; This takes SOME_VAR=foo make some-targetThis sets the make var; make SOME_VAR=foo some-targetI got bit by that because macOS and Linux |
We recently switched VERSION to be read from env vars (#4270). This
broke several projects, as they were building runc and using a
VERSIONenv var for, e.g. the containerd version.
When fixing that in #4370, we discussed to consider doing the same for
these variables too
(#4370 (review)).
Let's stop reading them from env vars, as it is very easy to do it by
mistake (e.g. compile runc and define a COMMIT env var, not to override
the commit shown in
runc --version) and users that want can stilloverride them if they want to. For example, with: