Remove kernel-compile and add perf package#2047
Merged
rn merged 8 commits intolinuxkit:masterfrom Jun 15, 2017
Merged
Conversation
iAdd a bunch of packages which are useful for compiling some of the tools shipped with the Linux kernel source code. Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
Also add additional tools and libraries useful/needed for compiling some of the ./tools in the kernel source. Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
projects are still using it, but it's still on hub so no impact. Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
This cherry-picks 120010cb1eea151d38a3e66f5ffc79a0c3110292 ("tools build:
Add test for sched_getcpu()") which replaces a #ifdef based test with
a proper test for the sched_getcpu() function. The macro based condition
does not work on Alpine as it is conditional on GLIBC.
For 4.9 the cherry-pick needed some manual adjustment and also required
commit ef2c3e76d98dfb69a46d870b47656e8e5bac6e2b ("perf jit: Avoid returning
garbage for a ret variable")
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
The perf utility is somewhat kernel specific so might as well compile it when we compile the kernel. The resulting binary is statically linked (and stripped for size) and is added the resulting kernel packages. Although we add alpine packages such as libunwind and other, it seems that the config detection code for perf/tools does not detect them. Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
Extract the perf binary from the kernel package and create a new perf package for each kernel. The perf package uses the same tags as the kernel package and only contains the perf binary under /usr/bin. The perf package can be added to the init section or included as a stage in a multi-stage build for other packages. Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
It's not build as part of the kernel build. Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
justincormack
approved these changes
Jun 15, 2017
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The first part of the PR replaces the
kernel-compilepackage with the alpine base image from which the build tools are installed during the kernel build.The second adds compilation and packaging of the Linux
perfutility to the kernel build.perfis typically matched with the kernel so we create akernel-perfpackage which is tagged the same as the kernel packages. Compilingperfrequired a few cherry picks for 4.9 and 4.11 kernels. Theperftools is not compiled for the 4.4 kernels as it was too tedious to get it to compile.resolves #1613