Opened 8 years ago

Closed 8 years ago

Last modified 8 years ago

#3961 closed task (wontfix)

Linux-4.7 ask for elfutils

Reported by: Thierry Nuttens Owned by: lfs-book@…
Priority: normal Milestone: 7.10
Component: Book Version: SVN
Severity: normal Keywords:
Cc:

Description

It look like kernel 4.7 is asking for a new dep: elfutils

Change History (5)

comment:1 by bdubbs@…, 8 years ago

We need more information. this does not make sense. The kernel cannot use any user space files like elfutils. I just ran a check in a pristine LFS environment with no problems:

   19  tar -xf linux-4.7.tar.xz
   20  cd linux-4.7
   21  make defconfig
   22  make menuconfig
   23  make
   24  make modules_install

comment:2 by Douglas R. Reno, 8 years ago

In the Makefile in the root of the source tree:

prepare0: archprepare
	$(Q)$(MAKE) $(build)=.

# All the preparing..
prepare: prepare0 prepare-objtool

ifdef CONFIG_STACK_VALIDATION
  has_libelf := $(call try-run,\
		echo "int main() {}" | $(HOSTCC) -xc -o /dev/null -lelf -,1,0)
  ifeq ($(has_libelf),1)
    objtool_target := tools/objtool FORCE
  else
    $(warning "Cannot use CONFIG_STACK_VALIDATION, please install libelf-dev or elfutils-libelf-devel")
    SKIP_STACK_VALIDATION := 1
    export SKIP_STACK_VALIDATION
  endif
endif

It seems that if CONFIG_STACK_VALIDATION is requested/set, elfutils is required (specifically libelf - probably for an interpreter during compilation)

comment:3 by bdubbs@…, 8 years ago

OK, I looked at the help for STACK_VALIDATION

 Symbol: STACK_VALIDATION                                 │  
  │ Type  :                                               │  
  │ Prompt: Compile-time stack metadata validation        |

That would be for a kernel developer. I suppose we could add a note with a reference to BLFS, but we do not need to add elfutils to LFS.

I'm really don't think that even a note is needed. After all, the STACK_VALIDATION option is at

  Kernel Hacking -->
    Compile-time checks and compiler options -->
      [ ] Compile-time stack metadata validation

and is not on by default.

comment:4 by bdubbs@…, 8 years ago

Resolution: wontfix
Status: newclosed

After thinking about it, I don't think we need to make any changes for this.

comment:5 by Thierry Nuttens, 8 years ago

Thanks a lot for your clarification. Totally agreed.

Note: See TracTickets for help on using tickets.