Re: powerpc{32,64} randconfigs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi

Le 21/04/2021 à 01:31, Randy Dunlap a écrit :
[time passes]

OK, I have a patch that seems for work as far as setting
PPC32=y or PPC64=y... but it has a problem during linking
of vmlinux:

crosstool/gcc-9.3.0-nolibc/powerpc-linux/bin/powerpc-linux-ld:./arch/powerpc/kernel/vmlinux.lds:6: syntax error

and the (bad) generated vmlinux.lds file says (at line 6):

OUTPUT_ARCH(1:common)

while it should say:

OUTPUT_ARCH(powerpc:common)

Does anyone have any ideas about this problem?

The following change fixes the problem, allthough I guess that's not what you want to do at the end.

diff --git a/scripts/Makefile.build b/scripts/Makefile.build
index 1b6094a13034..00f72699c518 100644
--- a/scripts/Makefile.build
+++ b/scripts/Makefile.build
@@ -358,7 +358,7 @@ targets += $(lib-y) $(always-y) $(MAKECMDGOALS)
 # Linker scripts preprocessor (.lds.S -> .lds)
 # ---------------------------------------------------------------------------
 quiet_cmd_cpp_lds_S = LDS     $@
-      cmd_cpp_lds_S = $(CPP) $(cpp_flags) -P -U$(ARCH) \
+      cmd_cpp_lds_S = $(CPP) $(cpp_flags) -P -U$(SRCARCH) \
 	                     -D__ASSEMBLY__ -DLINKER_SCRIPT -o $@ $<

 $(obj)/%.lds: $(src)/%.lds.S FORCE



The ARCH=ppc32 / ARCH=ppc64 patch is below FYI.
It is missing an update to Documentation/kbuild/kbuild.rst (aliases).


thanks.




[Index of Archives]     [Linux&nblp;USB Development]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite Secrets]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux