8000 build: add --with-stage1-systemd-revision option for src build by s-urbaniak · Pull Request #3362 · rkt/rkt · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
This repository was archived by the owner on Feb 24, 2020. It is now read-only.

build: add --with-stage1-systemd-revision option for src build #3362

Merged
merged 1 commit into from
Nov 21, 2016

Conversation

s-urbaniak
Copy link
Contributor

Currently the systemd version can be specified using
--with-stage1-systemd-version. The build system uses this value to
chcek out the systemd revision and uses the same value to set the
systemd version.

While this works nicely for building vXXX based tags, it causes
problems with custom systemd branch builds where an arbitrary branch
name does not map to a qualified systemd version.

Since rkt uses heuristics internally to evaluate the systemd version,
this causes conflicts.

This fixes it by introducing a new --with-stage1-systemd-revision
configure parameter to distinguish the systemd version, and revision
being built.

Fixes #3344

@s-urbaniak s-urbaniak added this to the v1.19.0 milestone Nov 9, 2016
@lucab
Copy link
Member
lucab commented Nov 9, 2016

Giving some time for @evverx to check this, postponing to next milestone.

@evverx
Copy link
Contributor
evverx commented Nov 9, 2016

@s-urbaniak , thanks!

But I can (accidentally) omit the --with-stage1-systemd-revision:

# I extracted this from the bash history
./configure --enable-functional-tests --with-stage1-systemd-src=~/systemd --with-stage1-systemd-version=master --with-stage1-flavors=src
...
        systemd git revision:                   'master'
        systemd version:                        'master'
...
make

I think we should reject such versions.

BTW: we know

  • the path to the repo
  • the branch name

Why not to run something like

(git describe --contains BRANCH) || ($(git describe BRANCH) + 1)

?

Currently the systemd version can be specified using
--with-stage1-systemd-version. The build system uses this value to
chcek out the systemd revision and uses the same value to set the
systemd version.

While this works nicely for building `vXXX` based tags, it causes
problems with custom systemd branch builds where an arbitrary branch
name does not map to a qualified systemd version.

Since rkt uses heuristics internally to evaluate the systemd version,
this causes conflicts.

This fixes it by introducing a new --with-stage1-systemd-revision
configure parameter to distinguish the systemd version, and revision
being built.

Fixes rkt#3344
@s-urbaniak
Copy link
Contributor Author

@evverx The path is known in your example, i.e. --with-stage1-systemd-src=~/systemd, but one can also specify --with-stage1-systemd-src=https://github.com/systemd/systemd.git (which is also the default).

So having a git-oneliner in the configure phase to determine the preceding/following tag name is not as easy as this patch; we need to check out the referenced repository first.

As good as this sounds I won't have time right now to dig deeper in the Makefile architecture to find the right spots at least to implement the requested enhanced version validation :-(

@lucab I added another small addition to the build-and-run-tests.sh script to actually also fix our src_master Jenkins build which will take a third parameter, namely the revision. The build matrix and the jenkins build script then only has to be changed for the src builds from src_master to src_master_v999, and from src_v231 to src_v231_v231 (I can do that once merged).

Finally I changed the defaults in the sec flavor build, RKT_STAGE1_SYSTEMD_VER=v999, and RKT_STAGE1_SYSTEMD_REV=master.

@evverx
Copy link
Contributor
evverx commented Nov 17, 2016

@s-urbaniak , I think the --with-stage1-systemd-version=v... is good enough. I use it and I'm happy :-)
Thanks!

Copy link
Member
@lucab lucab left a comment

Choose a reason for hiding this comment

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

LGTM

@lucab lucab merged commit 5e93c4a into rkt:master Nov 21, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

./configure --with-stage1-systemd-version=master changes the rkt-behaviour due to GetFlavor == 0
3 participants
0