Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1539789

Re: [regression ?] kbuild: fix building bzImage with CONFIG_TRIM_UNUSED_KSYMS enabled

From Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com>
Newsgroups linux.kernel
Subject Re: [regression ?] kbuild: fix building bzImage with CONFIG_TRIM_UNUSED_KSYMS enabled
Date 2016-12-10 08:30 +0100
Message-ID <sMKgx-5ZP-5@gated-at.bofh.it> (permalink)
References <sMjq2-5Sr-19@gated-at.bofh.it> <sMjzH-5WL-1@gated-at.bofh.it> <sMkm6-6zB-3@gated-at.bofh.it> <sMlrP-7fm-5@gated-at.bofh.it> <sMxMl-6wk-23@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On (12/09/16 13:07), Nicolas Pitre wrote:
[..]
> > build:
> > make -j4 > build_log 2>&1
> > 
> > package:
> > make -j4 INSTALL_MOD_PATH="${pkgdir}" modules_install >> build_log 2>&1
> 
> Weird.

it is. sorry for long reply, it took me some time to track it down.
turned out, the script also does `prepare' and `kernelrelease'. so
the sequence of commands in my build script is

	make prepare
	make kernelrelease
# functon build
	make -j4
# finction package
	make -j4 INSTALL_MOD_PATH=XXXX modules_install


now. the problem here is that, apparently, and I didn't know that,
"make prepare" and "make kernelrelease" are executed twice.

- first time when I build the kernel
 make prepare
 make kernelrelease
 make -j4

- second time when I install the modules
 make prepare
 make kernelrelease
 make -j4 INSTALL_MOD_PATH=XXXX modules_install


so this will not install modules:
 make prepare; make kernelrelease; make -j4; make prepare; make kernelrelease; make -j4 INSTALL_MOD_PATH=/tmp/MODULES modules_install

and this will:
 make prepare; make kernelrelease; make -j4; make kernelrelease; make -j4 INSTALL_MOD_PATH=/tmp/MODULES modules_install


> You must have CONFIG_TRIM_UNUSED_KSYMS=y in your .config, right?

yes.

> What if you set it to n instead without reverting 865563924022d8. Do you 
> still have the same issue?

!CONFIG_TRIM_UNUSED_KSYMS or !865563924022d8 builds just fine with extra
`make prepare'.
no `extra make prepare' builds ok regardless the state of Makefile/config
files.

I guess you don't need my .config any more.

	-ss

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[regression ?] kbuild: fix building bzImage with  CONFIG_TRIM_UNUSED_KSYMS enabled Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com> - 2016-12-09 03:50 +0100
  Re: [regression ?] kbuild: fix building bzImage with  CONFIG_TRIM_UNUSED_KSYMS enabled Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com> - 2016-12-09 04:00 +0100
    Re: [regression ?] kbuild: fix building bzImage with CONFIG_TRIM_UNUSED_KSYMS  enabled Nicolas Pitre <nicolas.pitre@linaro.org> - 2016-12-09 04:50 +0100
      Re: [regression ?] kbuild: fix building bzImage with  CONFIG_TRIM_UNUSED_KSYMS enabled Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com> - 2016-12-09 06:00 +0100
        Re: [regression ?] kbuild: fix building bzImage with CONFIG_TRIM_UNUSED_KSYMS  enabled Nicolas Pitre <nicolas.pitre@linaro.org> - 2016-12-09 19:10 +0100
          Re: [regression ?] kbuild: fix building bzImage with  CONFIG_TRIM_UNUSED_KSYMS enabled Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com> - 2016-12-10 08:30 +0100
            Re: [regression ?] kbuild: fix building bzImage with CONFIG_TRIM_UNUSED_KSYMS  enabled Nicolas Pitre <nicolas.pitre@linaro.org> - 2016-12-10 22:10 +0100
              Re: [regression ?] kbuild: fix building bzImage with  CONFIG_TRIM_UNUSED_KSYMS enabled Sergey Senozhatsky <sergey.senozhatsky@gmail.com> - 2016-12-11 03:20 +0100

csiph-web