'kconfig edit' broken when cross compiling is not needed
This was caused by the changes in !2023 (merged).
When the target arch == native arch, it tries to install things that make no sense:
(429248) [19:43:09] (native) calculate depends of ccache-cross-symlinks, gcc-x86_64, g++-x86_64 (pmbootstrap -v for details)
(429248) [19:43:09] ERROR: Could not find dependency 'gcc-x86_64' in any aports folder or APKINDEX. See <https://postmarketos.org/depends>
I applied the following patch to pmb/build/init.py
, which works around the above error:
diff --git a/pmb/build/init.py b/pmb/build/init.py
index 480352875..4bc4cecd3 100644
--- a/pmb/build/init.py
+++ b/pmb/build/init.py
@@ -86,8 +86,10 @@ def init_compiler(args, depends, cross, arch):
cross_pkgs += ["gcc4-" + arch]
elif "gcc6" in depends:
cross_pkgs += ["gcc6-" + arch]
- else:
+ elif arch != args.arch_native:
cross_pkgs += ["gcc-" + arch, "g++-" + arch]
+ else:
+ cross_pkgs += ["gcc", "g++"]
if "clang" in depends or "clang-dev" in depends:
cross_pkgs += ["clang"]
if cross == "crossdirect":
However there's another failure later from menuconfig:
scripts/kconfig/mconf Kconfig
scripts/Kconfig.include:36: linker 'x86_64-alpine-linux-musl-ld' not found
make[1]: *** [scripts/kconfig/Makefile:33: menuconfig] Error 1
make: *** [Makefile:590: menuconfig] Error 2
I haven't had time to look into it any further than that. @z3ntu fyi