Subject: under x86_64, bootstrap i486 build. stopped at lua5.5 dependency

From: 尤晓杰 <[email-masked]>
Date: Fri, 26 Dec 2025 18:37:43 +0800 (CST)

git clone aports to harddisk, modified i586-linux-musl triplet in function.sh to i486 and run ./bootstrap.sh x86, stopped at building apk-tools.
log as follows:
>>> bootstrap-x86: Building cross-compiler
>>> binutils-x86: Package is up to date
>>> libucontext: Package is up to date
>>> gcc-x86: Package is up to date
>>> build-base-x86: Package is up to date
>>> bootstrap-x86: Cross building base system
>>> fortify-headers: Package is up to date
>>> linux-headers: Package is up to date
>>> musl: Package is up to date
>>> zlib: Package is up to date
>>> pkgconf: Package is up to date
>>> gmp: Package is up to date
>>> mpfr4: Package is up to date
>>> mpc1: Package is up to date
>>> isl26: Package is up to date
>>> libucontext: Package is up to date
>>> zstd: Package is up to date
>>> binutils: Package is up to date
>>> gcc: Package is up to date
>>> make: Package is up to date
>>> file: Package is up to date
>>> patch: Package is up to date
>>> openssl: Package is up to date
>>> busybox: Package is up to date
>>> build-base: Package is up to date
>>> ca-certificates: Package is up to date
>>> libmd: Package is up to date
>>> bsd-compat-headers: Package is up to date
>>> libbsd: Package is up to date
>>> apk-tools: Building main/apk-tools 3.0.3-r1 (using abuild 3.16.0-r0) started Fri, 26 Dec 2025 17:42:18 +0800
>>> apk-tools: Validating /home/allan/aports/main/apk-tools/APKBUILD...
>>> apk-tools: Analyzing dependencies...
ERROR: unable to select packages:
  .makedepends-apk-tools-20251226.094219:
    masked in: cache
    satisfies: world[.makedepends-apk-tools=20251226.094219]
  lua5.5 (no such package):
    required by: .makedepends-apk-tools-20251226.094219[lua5.5]
  lua5.5-lzlib (no such package):
    required by: .makedepends-apk-tools-20251226.094219[lua5.5-lzlib]
>>> ERROR: apk-tools: builddeps failed
>>> apk-tools: Uninstalling dependencies...
ERROR: No such package: .makedepends-apk-tools
ERROR: No such package: .hostdepends-apk-tools

---

From: "Achill Gilgenast" <[email-masked]>
Date: Fri, 26 Dec 2025 11:42:14 +0100

> ERROR: No such package: .hostdepends-apk-tools

Please make sure your index is up-to-date (apk update) and try again.

---

From: 尤晓杰 <[email-masked]>
Date: Fri, 26 Dec 2025 19:39:50 +0800 (CST)

thanks.I&nbsp;did&nbsp;it,&nbsp;let&nbsp;me&nbsp;try&nbsp;again.&nbsp;btw,&nbsp;do&nbsp;you&nbsp;know&nbsp;how&nbsp;i&nbsp;can&nbsp;see&nbsp;the&nbsp;commit&nbsp;of&nbsp;kernel?&nbsp;the&nbsp;diff&nbsp;file&nbsp;seems&nbsp;no&nbsp;comments.&nbsp;if&nbsp;there&nbsp;is&nbsp;git,&nbsp;it&nbsp;is&nbsp;ok&nbsp;or&nbsp;patch&nbsp;management&nbsp;website.
在 2025-12-26 18:42:14，"Achill Gilgenast" <[email-masked]> 写道：

---

From: 尤晓杰 <[email-masked]>
Date: Fri, 26 Dec 2025 21:05:27 +0800 (CST)

is&nbsp;it&nbsp;because&nbsp;I&nbsp;am&nbsp;using&nbsp;3.23.2-stable?&nbsp;should&nbsp;I&nbsp;changed&nbsp;to&nbsp;edge&nbsp;branch?&nbsp;modify&nbsp;repository?
在 2025-12-26 18:42:14，"Achill Gilgenast" <[email-masked]> 写道：

---

From: "Sertonix" <[email-masked]>
Date: Fri, 26 Dec 2025 14:38:10 +0000

>     required by: .makedepends-apk-tools-20251226.094219[lua5.5-lzlib]

The apk-tools package has recently been switched to lua5.5. A very new
lua version which has only been available on alpine edge for a few days.

Since the lua version while bootstrapping is not important you can apply
a patch like this to fix compilation when lua5.5 is not available without
changing the resulting package.

diff --git a/main/apk-tools/APKBUILD b/main/apk-tools/APKBUILD
index b8b87a589a2..3e0373b04ee 100644
--- a/main/apk-tools/APKBUILD
+++ b/main/apk-tools/APKBUILD
@@ -22,6 +22,7 @@ depends="
 	libapk=$pkgver-r$pkgrel
 	"
 _lua="5.5"
+[ -n "$BOOTSTRAP" ] && _lua="5.3"
 makedepends_build="meson openssl-dev>=3.5 lua$_lua lua$_lua-lzlib scdoc"
 makedepends_host="
 	linux-headers

---

From: 尤晓杰 <[email-masked]>
Date: Sat, 27 Dec 2025 00:10:05 +0800 (CST)

1thanks&nbsp;for&nbsp;your&nbsp;patience.&nbsp;just&nbsp;switch&nbsp;debian&nbsp;to&nbsp;arch&nbsp;and&nbsp;alpine.After&nbsp;your&nbsp;explanation&nbsp;I&nbsp;see&nbsp;using&nbsp;3.23.2&nbsp;stable&nbsp;to&nbsp;build&nbsp;git&nbsp;master,&nbsp;this&nbsp;is&nbsp;the&nbsp;reason&nbsp;of&nbsp;this&nbsp;error.&nbsp;if&nbsp;I&nbsp;upgrade&nbsp;to&nbsp;edge,&nbsp;should&nbsp;it&nbsp;be&nbsp;ok?&nbsp;&nbsp;2the&nbsp;unpatched&nbsp;authentic&nbsp;kernel&nbsp;could&nbsp;be&nbsp;compiled&nbsp;with&nbsp;musl&nbsp;lib&nbsp;successfully?&nbsp;the&nbsp;other&nbsp;expression&nbsp;is&nbsp;whether&nbsp;kernel&nbsp;and&nbsp;the&nbsp;lib&nbsp;we&nbsp;take&nbsp;has&nbsp;conecxion.&nbsp;we&nbsp;need&nbsp;modify&nbsp;kernel&nbsp;to&nbsp;adopt&nbsp;to&nbsp;musl?&nbsp;I&nbsp;suspect&nbsp;most&nbsp;of&nbsp;the&nbsp;patches&nbsp;of&nbsp;kernel&nbsp;is&nbsp;for&nbsp;such&nbsp;purpose.

---

From: "Sertonix" <[email-masked]>
Date: Fri, 26 Dec 2025 16:40:51 +0000

On Fri Dec 26, 2025 at 5:10 PM CET, 尤晓杰 wrote:
> thanks for your patience. just switch debian to arch and alpine. After
> your explanation I see using 3.23.2 stable to build git master, this
> is the reason of this error. if I upgrade to edge, should it be ok?

There could be some soname issues when upgrading CBUILD while bootstrapping
but otherwise it should be ok.

> the unpatched authentic kernel could be compiled with musl lib
> successfully? the other expression is whether kernel and the lib we
> take has conecxion. we need modify kernel to adopt to musl? I suspect
> most of the patches of kernel is for such purpose.

The kernel does not need patches for musl libc. Both glibc and musl libc
use the same kernel interfaces without modifications.

---

From: 尤晓杰 <[email-masked]>
Date: Sun, 28 Dec 2025 00:37:01 +0800 (CST)

dear&nbsp;friend,is&nbsp;there&nbsp;document&nbsp;for&nbsp;crossbuilding&nbsp;and&nbsp;making&nbsp;rootfs?&nbsp;or&nbsp;bootstrap.sh&nbsp;genapkovl-dhcp.sh&nbsp;genrootfs.sh&nbsp;and&nbsp;mkimage.sh?

I&nbsp;am&nbsp;ashamed&nbsp;to&nbsp;troubled&nbsp;you&nbsp;again&nbsp;and&nbsp;again.&nbsp;this&nbsp;time&nbsp;I&nbsp;uncomment&nbsp;all&nbsp;opticial&nbsp;software&nbsp;in&nbsp;bootstrap.sh.&nbsp;so&nbsp;I&nbsp;see&nbsp;kernel&nbsp;and&nbsp;other&nbsp;stuffs.&nbsp;and&nbsp;how&nbsp;to&nbsp;produce&nbsp;rootfs&nbsp;file?
在 2025-12-27 00:40:51，Sertonix <[email-masked]> 写道：

---

From: 尤晓杰 <[email-masked]>
Date: Sun, 28 Dec 2025 02:33:22 +0800 (CST)

when&nbsp;bootstrap,should&nbsp;curl&nbsp;need&nbsp;nghttp3-dev?&nbsp;

log:

&nbsp;libev:&nbsp;Package&nbsp;is&nbsp;up&nbsp;to&nbsp;date
>>>c-ares:&nbsp;Package&nbsp;is&nbsp;up&nbsp;to&nbsp;date
>>>cunit:&nbsp;Package&nbsp;is&nbsp;up&nbsp;to&nbsp;date
>>>&nbsp;nghttp2:&nbsp;Package&nbsp;is&nbsp;up&nbsp;to&nbsp;date
>>>&nbsp;1ibidnz:&nbsp;Package&nbsp;is&nbsp;up&nbsp;to&nbsp;date
>>>&nbsp;libunistring：&nbsp;Package&nbsp;is&nbsp;up&nbsp;to&nbsp;date
>>>&nbsp;libpsl:&nbsp;Package&nbsp;is&nbsp;up&nbsp;to&nbsp;date
>>>&nbsp;curl:&nbsp;Building&nbsp;main/curl8.17.0-r1(using&nbsp;abuild3.16&nbsp;.0-r0)&nbsp;started&nbsp;Sun,28
Dec&nbsp;&nbsp;202502:29:27&nbsp;+0800
>>>&nbsp;curl:&nbsp;Ualidating/home/allan/aports/main/cur&nbsp;/APKBUILD
>>>&nbsp;curl:&nbsp;Analyzing&nbsp;dependencies
ERROR:&nbsp;umable&nbsp;to&nbsp;select&nbsp;packages:
hostdepends-curI-20251227.182928:
masked&nbsp;in:&nbsp;cache
satisfies:&nbsp;worldl&nbsp;hostdepends-curl=20251227.182928]
nghttp3-dev&nbsp;(no&nbsp;such&nbsp;package):
required&nbsp;by:&nbsp;.host&nbsp;depends-cur1-20251227.182928[nghttp3-dev]
>>>&nbsp;ERROR:curl:&nbsp;builddeps&nbsp;failed
>>curl:&nbsp;Uninstalling&nbsp;dependenc&nbsp;ies.
ERROR:&nbsp;Mo&nbsp;such&nbsp;package:.makedepends-curl
ERROR:&nbsp;No&nbsp;such&nbsp;package:hostdepends-curl

I&nbsp;am&nbsp;in&nbsp;edge&nbsp;now.
在 2025-12-27 00:40:51，Sertonix <[email-masked]> 写道：