Re: [PATCH] make-mod-scripts: Provide the correct objcopy to kernel make
Bruce Ashfield
On Thu, Mar 25, 2021 at 9:13 PM Nishanth Menon via
lists.openembedded.org <nm=ti.com@...> wrote: As I mentioned to Denys, I hadn't seen this. Consulting the maintainers file would have found me as a good addition to the cc'. I'm doing some other work on make-mod-scripts dependencies right now, so I've pulled this in and will re-test against all of the active kernel versions in master. But I don't think that make-mod-scripts is the only place we'd need this, if it is indeed happening on the tip of all the supported versions. There are routes to have the prepare steps run, without a make-mod-scripts dependency. We've already made the mistake of letting the make-mod-scrips and kernel build parameters diverge (see AR=${KERNEL_AR}), so I need to spend a few minutes getting them back in sync. I was just able to build and boot qemuarm64 on 5.12-rc4, so there's something different about your config than my setup. We need to figure that out. It could be a .config triggering different components to be built, but unlikely given vdso being involved. qemuarm64 login: root root@qemuarm64:~# uname -a Linux qemuarm64 5.12.0-rc4-yoctodev-standard #1 SMP PREEMPT Mon Mar 22 18:46:22 UTC 2021 aarch64 aarch64 aarch64 GNU/Linux root@qemuarm64:~# [1] https://pastebin.ubuntu.com/p/pNcQtb93wr/We shouldn't need this TARGET_OBJCOPY_KERNEL_ARCH -> HOST_OBJCOPY_KERNEL_ARCH, I can't think of how objcopy would be using them. Are you setting them to some value in your builds ? KERNEL_CC = "${CCACHE}${HOST_PREFIX}gcc ${HOST_CC_KERNEL_ARCH} -fuse-ld=bfd ${DEBUG_PREFIX_MAP} -fdebug-prefix-map=${STAGING_KERNEL_DIR}=${KERNEL_SRC_PATH}"The main kernel Makefile already defines, and the standard env should already have both CROSS_COMPILE and OBJCOPY defined to be the target version. Makefile:OBJCOPY = $(CROSS_COMPILE)objcopy So we really have to pass this, when fundamentally it is the same definition as what the defaults give us. What does that resolve to in your builds ? In mine, when I dump the objcopy value from within the kernel build, I get: | /opt/poky/build/tmp/work-shared/qemuarm64/kernel-source/Makefile:443: *** objcopy: aarch64-poky-linux-objcopy. Stop. Which should be doing the job. Are you building arm on arm ? or something else like that ? Bruce TOOLCHAIN = "gcc" -- - Thou shalt not follow the NULL pointer, for chaos and madness await thee at its end - "Use the force Harry" - Gandalf, Star Trek II |
|